@@ -44,6 +44,7 @@ public function getShared(): string
4444 public function matchesShared (string |ResourceState $ state ): bool
4545 {
4646 $ state = $ this ->resolveState ($ state );
47+
4748 return $ this ->getShared () === $ state ;
4849 }
4950
@@ -70,14 +71,15 @@ public function getForResource(string $resourceClass): string
7071 public function matchesResource (string $ resourceClass , string |ResourceState $ state ): bool
7172 {
7273 $ state = $ this ->resolveState ($ state );
74+
7375 return $ this ->getForResource ($ resourceClass ) === $ state ;
7476 }
7577
7678 /**
7779 * Get the current state for a resource.
7880 * If no resource class is provided, returns the shared state.
7981 *
80- * @param string|null $resourceClass
82+ * @param string|null $resourceClass
8183 */
8284 public function get ($ resourceClass = null ): string
8385 {
@@ -92,8 +94,8 @@ public function get($resourceClass = null): string
9294 * Set the current state for a resource.
9395 * If no resource class is provided, sets the shared state.
9496 *
95- * @param string|ResourceState $state
96- * @param string|null $resourceClass
97+ * @param string|ResourceState $state
98+ * @param string|null $resourceClass
9799 */
98100 public function set ($ state , $ resourceClass = null ): void
99101 {
@@ -110,8 +112,8 @@ public function set($state, $resourceClass = null): void
110112 * Check if the current state matches the given state for a resource.
111113 * If no resource class is provided, checks against the shared state.
112114 *
113- * @param string|ResourceState $state
114- * @param string|null $resourceClass
115+ * @param string|ResourceState $state
116+ * @param string|null $resourceClass
115117 */
116118 public function matches ($ state , $ resourceClass = null ): bool
117119 {
0 commit comments