diff --git a/src/Content/Translation.php b/src/Content/Translation.php index c5866f36dd..36803207e1 100644 --- a/src/Content/Translation.php +++ b/src/Content/Translation.php @@ -45,6 +45,7 @@ public function __debugInfo(): array */ public function code(): string { + Helpers::deprecated('`$translation->code()` has been deprecated. Use `$translation->language()->code()` instead.', 'translation-code'); return $this->language->code(); } @@ -56,6 +57,7 @@ public function code(): string */ public function content(): array { + Helpers::deprecated('`$translation->content()` has been deprecated. Use `$translation->version()->content()` instead.', 'translation-content'); return $this->version->content($this->language)->toArray(); } @@ -66,6 +68,7 @@ public function content(): array */ public function contentFile(): string { + Helpers::deprecated('`$translation->contentFile()` has been deprecated. Use `$translation->version()->contentFile()` instead.', 'translation-contentFile'); return $this->version->contentFile($this->language); } @@ -100,6 +103,7 @@ public static function create( */ public function exists(): bool { + Helpers::deprecated('`$translation->exists()` has been deprecated. Use `$translation->version()->exists()` instead.', 'translation-exists'); return $this->version->exists($this->language); } @@ -119,6 +123,7 @@ public function id(): string */ public function isDefault(): bool { + Helpers::deprecated('`$translation->isDefault()` has been deprecated. Use `$translation->language()->isDefault()` instead.', 'translation-isDefault'); return $this->language->isDefault(); }