Skip to content

Commit af5584e

Browse files
committed
Fix SplObjectStorage deprecations in WindowManager
1 parent b1bcf22 commit af5584e

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/Window/Manager/WindowManager.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ private static function createEventListener(PsrEventDispatcherInterface $dispatc
131131
private function registerDefaultEventListeners(): void
132132
{
133133
$this->listener->addEventListener(WindowClosed::class, function (WindowClosed $event) {
134-
$this->windows->detach($event->subject);
134+
$this->windows->offsetUnset($event->subject);
135135

136136
// Recalculate default window in case of
137137
// previous default window was closed.
@@ -147,7 +147,7 @@ public function create(WindowCreateInfo $info = new WindowCreateInfo(), bool $de
147147
? $this->createWindowProxy($info)
148148
: $this->createWindowInstance($info);
149149

150-
$this->windows->attach($instance, $info);
150+
$this->windows->offsetSet($instance, $info);
151151

152152
return $instance;
153153
}

0 commit comments

Comments
 (0)