DEV Community

Discussion on: Get, set... STOP!

Collapse
 
dmahely profile image
Doaa Mahely

Interesting article. Do you think it’s better (clearer, cleaner, etc) to have 2 separate activate and deactivate methods or one method updateStatus that takes a boolean argument?

Collapse
 
konrad_126 profile image
konrad_126

Hello Doaa,

Yes, that would be in line with what I'm recommending in this article.

Collapse
 
vlasales profile image
Vlastimil Pospichal

Yes, I prefer activate and deactivate. It's no setting boolean only. You may propagate this state into dependencies.