Page MenuHomePhorge

Simplify setStatusAttribute
ClosedPublic

Authored by mollekopf on Feb 26 2023, 2:36 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Apr 21, 5:07 PM
Unknown Object (File)
Sun, Apr 21, 5:07 PM
Unknown Object (File)
Sun, Apr 21, 5:07 PM
Unknown Object (File)
Sun, Apr 21, 5:07 PM
Unknown Object (File)
Sun, Apr 21, 5:07 PM
Unknown Object (File)
Wed, Apr 17, 10:11 AM
Unknown Object (File)
Sat, Apr 13, 8:44 PM
Unknown Object (File)
Sat, Apr 13, 6:31 PM
Subscribers

Details

Summary

To me this is easier to understand, and I suppose it's theoretically the more performant solution (I doubt it matters).
Discard if you don't like it.

Diff Detail

Repository
rK kolab
Lint
Lint Errors
SeverityLocationCodeMessage
Errorsrc/app/Group.php:48phpstanProperty App\Group::$allowed_states is never read, only written.
Errorsrc/app/Resource.php:49phpstanProperty App\Resource::$allowed_states is never read, only written.
Errorsrc/app/SharedFolder.php:52phpstanProperty App\SharedFolder::$allowed_states is never read, only written.
Errorsrc/app/User.php:65phpstanProperty App\User::$allowed_states is never read, only written.
Unit
No Test Coverage
Build Status
Buildable 41855
Build 16802: arc lint + arc unit

Event Timeline

mollekopf created this revision.
mollekopf added a reviewer: Restricted Project.

I fine with it, but it would make sense to unify the similar code in App\Domain and App\Traits\StatusPropertyTrait.

Unified the status attribute handling

machniak requested changes to this revision.Mar 5 2023, 8:36 AM

Nice. We have to silence the linting error: Property App\SharedFolder::$allowed_states is never read, only written.

This revision now requires changes to proceed.Mar 5 2023, 8:36 AM

Nice. We have to silence the linting error: Property App\SharedFolder::$allowed_states is never read, only written.

I'm not getting that in the codebase, just here. I suppose because the arc linting has no visibility on the trait.

This revision is now accepted and ready to land.Mar 6 2023, 2:21 PM
This revision was landed with ongoing or failed builds.Mar 7 2023, 9:42 PM
This revision was automatically updated to reflect the committed changes.