Skip to content

MigrateToSimplifiedAttributeRector remove abstract modifier from the method #445

@cwang22

Description

@cwang22

these two rules will remove abstract modifier from the method

  • MigrateToSimplifiedAttributeRector
  • ScopeNamedClassMethodToScopeAttributedClassMethodRector
-    abstract public function getStatusAttribute(): string;
+    protected function status(): Attribute
+    {
+        return Attribute::make(get: static function () {
+        });
+    }

-    abstract public function scopeValid(Builder $q): Builder;
+    #[Scope]
+    protected function valid(Builder $q): Builder;

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions