char *start_path = NULL;
ms_user_storage_type_e storage_type;
ms_noti_type_e noti_type = MS_ITEM_INSERT;
- int delete_folder_count = 0;
char *folder_uuid = NULL;
while (1) {
ms_bacth_commit_disable(handle, TRUE, TRUE, scan_data->uid);
- if (ms_delete_invalid_items_in_folder(handle, storage_id, scan_data->msg, is_recursive, scan_data->uid) != MS_MEDIA_ERR_NONE) {
- MS_DBG_ERR("deleting invalid items in folder failed");
+ if (!ms_delete_invalid_items(handle, storage_id, storage_type, scan_data->uid)) {
+ MS_DBG_ERR("deleting invalid items in storage failed");
}
- /*remove invalid folder in folder table.*/
- if (ms_delete_invalid_folder_by_path(handle, storage_id, scan_data->msg, scan_data->uid, &delete_folder_count) != MS_MEDIA_ERR_NONE) {
- MS_DBG_ERR("deleting invalid folder failed");
+ if (ms_delete_invalid_folder(handle, storage_id, storage_type, scan_data->uid) != MS_MEDIA_ERR_NONE) {
+ MS_DBG_ERR("deleting invalid folders in storage failed");
}
if (ret != MS_MEDIA_ERR_SCANNER_FORCE_STOP) {