MDL-33416 Remove unused reference fields in files table

Fields files.referencelastsync and files.referencelifetime just waste the space and actually duplicate the fields
files_reference.lifetime and files_reference.lastsync
MDL-33416 Get rid of DB field files_reference.lifetime

It is absolutely unnecessary because there is an API function for it and all repositories return contant there anyway
MDL-33416
MDL-41774 Fixed bug in file synchronisation by handle
temp