Incomplete files uploaded to Nextcloud server

Nextcloud version 12.0.4

I’m syncing an app (Joplin) with Nextcloud ( and I’ve noticed that some of the files have only been partially uploaded.

It’s possible that the app was interrupted while uploading, but I’m wondering what is the normal behaviour of Nextcloud when doing a WebDAV PUT call? Does it put the file being uploaded aside and only replace it once it’s fully copied, or does it start overwriting what is already there directly?