Update UploadBehavior.php

Made most of Jose's recommendations.

Still some work to do, but getting there.
Update UploadBehavior.php

Added error suppression, and refactored deletion code to reflect Jose's recommendations.
Merge pull request #111 from benjaminallison/patch-3

Update UploadBehavior.php