[stable5] fix upload to /Shared

Backport of https://github.com/owncloud/core/pull/5193/ which should fix https://github.com/owncloud/core/issues/5126

write the part file to the users root folder if the updated file is located in /Shared because we can't create new files in Shared/

@DeepDiver1975 @dragotin please have a look, Thanks!