Need your advice about property name

Need your advice about property name 


Hello all, i have a service which is deleting old data from DB and from storage, this service have bool flag for deleting data only from storage. I struggle to name this property. I am thinking, what if another developer will read my code, which of the following conditions he/she/you will understand clearly:
if($cleanup->files_only)
if($cleanup->is_files_only)
if($cleanup->only_files)
if($cleanup->is_only_files)
I want to keep is_* prefix to go along with naming conventions for booleans, but files_only alone sounds like boolean, plus swapping with 'only_files ' sounds exactly same as files_only.
What do you think about naming this property, how would you name it?


Comments

Popular posts from this blog

A Tailwind CSS Preset for Laravel 5.5

Short and safe array iteration

PHPStorm's performance