Simplify if statement
Extract certain methods to increase readability of UploadBehavior::afterSave()
Refactor beforeSave to reduce NPath complexity
Rewrite unnecessary else clause
Add missing typehints
Refactor _setupField to reduce complexity