Move uploaded files between directories, updating all references in database