diff --git a/composer.json b/composer.json index 126b8864..81ce0825 100755 --- a/composer.json +++ b/composer.json @@ -26,6 +26,7 @@ "illuminate/encryption": "^13", "illuminate/events": "^13", "illuminate/filesystem": "^13", + "illuminate/hashing": "^13", "illuminate/http": "^13", "illuminate/log": "^13", "illuminate/macroable": "^13", @@ -64,7 +65,6 @@ "illuminate/auth": "self.version", "illuminate/exception": "self.version", "illuminate/foundation": "self.version", - "illuminate/hashing": "self.version", "illuminate/html": "self.version", "illuminate/mail": "self.version", "illuminate/queue": "self.version", diff --git a/src/Illuminate/Foundation/Application.php b/src/Illuminate/Foundation/Application.php index 6fbc787f..679be32d 100755 --- a/src/Illuminate/Foundation/Application.php +++ b/src/Illuminate/Foundation/Application.php @@ -1299,10 +1299,6 @@ public function registerCoreContainerAliases() $this->alias('encrypter', 'Illuminate\Contracts\Encryption\Encrypter'); $this->alias('encrypter', 'Illuminate\Contracts\Encryption\StringEncrypter'); - // BC: Hashing\HasherInterface → Contracts\Hashing\Hasher (task 2.11); keep old name resolvable. - // class_alias covers use/typehint/instanceof; make()/autowiring by the old name needs this. - $this->alias('hash', 'Illuminate\Hashing\HasherInterface'); - // L13 SCC-1 swap (task 4.1): the swapped components ship v13 contracts. Alias them to // the core bindings so v13 code that type-hints the contracts resolves (the v13 // providers don't always register these against the fork's core aliases). diff --git a/tests/Foundation/FoundationApplicationTest.php b/tests/Foundation/FoundationApplicationTest.php index 107d9382..b5fee1bd 100755 --- a/tests/Foundation/FoundationApplicationTest.php +++ b/tests/Foundation/FoundationApplicationTest.php @@ -30,16 +30,13 @@ public function testSetLocaleSetsLocaleAndFiresLocaleChangedEvent() } - public function testCoreAliasResolvesHashByBothContractAndLegacyName() + public function testCoreAliasResolvesHashByContract() { $app = new Application; $app->registerCoreContainerAliases(); $app->singleton('hash', function() { return new Illuminate\Hashing\BcryptHasher; }); $this->assertInstanceOf(Illuminate\Contracts\Hashing\Hasher::class, $app->make(Illuminate\Contracts\Hashing\Hasher::class)); - // BC: the pre-migration interface name must still resolve via make()/autowiring; - // class_alias only covers use/typehint/instanceof, not container resolution (task 2.11). - $this->assertInstanceOf(Illuminate\Contracts\Hashing\Hasher::class, $app->make('Illuminate\Hashing\HasherInterface')); }