adding better debugging output to local uploads
explicitely setting note.file.upload_id to -1 in add-note *if* file record is present. this lets the client know that a file has been saved but isnt uploaded YET
making sure that a request for a local file that doesnt exist will return a 404