Skip to content

Commit 0cacea4

Browse files
committed
Merge branch 'master' into 2.x-dev
2 parents 8247bdd + ef7cce7 commit 0cacea4

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

packages/framework/src/Foundation/Concerns/ForwardsHyperlinks.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
namespace Hyde\Foundation\Concerns;
66

77
use Hyde\Support\Models\Route;
8+
use JetBrains\PhpStorm\Deprecated;
89

910
/**
1011
* @internal Single-use trait for the HydeKernel class.
@@ -23,8 +24,14 @@ public function relativeLink(string $destination): string
2324
return $this->hyperlinks->relativeLink($destination);
2425
}
2526

27+
/**
28+
* @deprecated This method will be removed in v2.0. Please use `asset()` instead.
29+
*/
30+
#[Deprecated(reason: 'Use `asset` method instead.', replacement: '%class%::asset(%parameter0%)')]
2631
public function mediaLink(string $destination, bool $validate = false): string
2732
{
33+
trigger_deprecation('hyde/framework', '1.8.0', 'The %s() method is deprecated, use %s() instead.', __METHOD__, 'asset');
34+
2835
return $this->hyperlinks->mediaLink($destination, $validate);
2936
}
3037

0 commit comments

Comments
 (0)