@@ -88,7 +88,7 @@ discard block |
||
88 | 88 | * |
89 | 89 | * @param Model $model |
90 | 90 | * @param string $type |
91 | - * @param null $locale |
|
91 | + * @param null|string $locale |
|
92 | 92 | * @return Model |
93 | 93 | */ |
94 | 94 | public function attachToModel(Model $model, $type = '', $locale = null) |
@@ -118,6 +118,9 @@ discard block |
||
118 | 118 | return basename($this->getFileUrl($size)); |
119 | 119 | } |
120 | 120 | |
121 | + /** |
|
122 | + * @return string |
|
123 | + */ |
|
121 | 124 | public function getFileUrl($size = '') |
122 | 125 | { |
123 | 126 | $media = $this->getMedia(); |
@@ -25,6 +25,11 @@ |
||
25 | 25 | return basename($this->getFileUrl($type, '', $locale)); |
26 | 26 | } |
27 | 27 | |
28 | + /** |
|
29 | + * @param string $locale |
|
30 | + * |
|
31 | + * @return string |
|
32 | + */ |
|
28 | 33 | public function getFileUrl($type = '', $size = '', $locale = null) |
29 | 34 | { |
30 | 35 | if ($this->assets->first() === null || $this->assets->first()->pivot === null) { |