Remove redundant typing from DocBlocks
This commit is contained in:
@@ -22,7 +22,6 @@ class Analytics extends Model
|
||||
* automatically assigning a session value based on previous rows.
|
||||
*
|
||||
* @param array $attributes Model attributes.
|
||||
* @return static
|
||||
*/
|
||||
public static function createWithSession(array $attributes): static
|
||||
{
|
||||
|
||||
@@ -29,8 +29,6 @@ class Article extends Model
|
||||
|
||||
/**
|
||||
* Get the article user
|
||||
*
|
||||
* @return BelongsTo
|
||||
*/
|
||||
public function user(): BelongsTo
|
||||
{
|
||||
@@ -39,8 +37,6 @@ class Article extends Model
|
||||
|
||||
/**
|
||||
* Get all of the article's attachments.
|
||||
*
|
||||
* @return MorphMany
|
||||
*/
|
||||
public function attachments(): MorphMany
|
||||
{
|
||||
|
||||
@@ -33,8 +33,6 @@ class Attachment extends Model
|
||||
|
||||
/**
|
||||
* Get attachments attachable
|
||||
*
|
||||
* @return MorphTo
|
||||
*/
|
||||
public function attachable(): MorphTo
|
||||
{
|
||||
@@ -43,8 +41,6 @@ class Attachment extends Model
|
||||
|
||||
/**
|
||||
* Get the media for this attachment.
|
||||
*
|
||||
* @return BelongsTo
|
||||
*/
|
||||
public function media(): BelongsTo
|
||||
{
|
||||
|
||||
@@ -38,8 +38,6 @@ class Event extends Model
|
||||
|
||||
/**
|
||||
* Get all of the article's attachments.
|
||||
*
|
||||
* @return MorphMany
|
||||
*/
|
||||
public function attachments(): MorphMany
|
||||
{
|
||||
@@ -48,8 +46,6 @@ class Event extends Model
|
||||
|
||||
/**
|
||||
* Get all the associated users.
|
||||
*
|
||||
* @return BelongsToMany
|
||||
*/
|
||||
public function users(): BelongsToMany
|
||||
{
|
||||
|
||||
@@ -24,8 +24,6 @@ class EventUser extends Model
|
||||
|
||||
/**
|
||||
* Get the event for this attachment.
|
||||
*
|
||||
* @return BelongsTo
|
||||
*/
|
||||
public function event(): BelongsTo
|
||||
{
|
||||
@@ -34,8 +32,6 @@ class EventUser extends Model
|
||||
|
||||
/**
|
||||
* Get the user for this attachment.
|
||||
*
|
||||
* @return BelongsTo
|
||||
*/
|
||||
public function user(): BelongsTo
|
||||
{
|
||||
|
||||
@@ -100,8 +100,6 @@ class Media extends Model
|
||||
|
||||
/**
|
||||
* Model Boot
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
protected static function boot(): void
|
||||
{
|
||||
@@ -164,7 +162,6 @@ class Media extends Model
|
||||
* Variants Set Mutator.
|
||||
*
|
||||
* @param mixed $value The value to mutate.
|
||||
* @return void
|
||||
*/
|
||||
public function setVariantsAttribute(mixed $value): void
|
||||
{
|
||||
@@ -256,8 +253,6 @@ class Media extends Model
|
||||
|
||||
/**
|
||||
* Delete file and associated files with the modal.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function deleteFile(): void
|
||||
{
|
||||
@@ -279,7 +274,6 @@ class Media extends Model
|
||||
/**
|
||||
* Invalidate Cloudflare Cache.
|
||||
*
|
||||
* @return void
|
||||
* @throws InvalidArgumentException Exception.
|
||||
*/
|
||||
private function invalidateCFCache(): void
|
||||
@@ -311,8 +305,6 @@ class Media extends Model
|
||||
|
||||
/**
|
||||
* Get URL path
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getUrlPath(): string
|
||||
{
|
||||
@@ -322,8 +314,6 @@ class Media extends Model
|
||||
|
||||
/**
|
||||
* Return the file URL
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getUrlAttribute(): string
|
||||
{
|
||||
@@ -336,8 +326,6 @@ class Media extends Model
|
||||
|
||||
/**
|
||||
* Return the file owner
|
||||
*
|
||||
* @return BelongsTo
|
||||
*/
|
||||
public function user(): BelongsTo
|
||||
{
|
||||
@@ -348,7 +336,6 @@ class Media extends Model
|
||||
* Move files to new storage device.
|
||||
*
|
||||
* @param string $storage The storage ID to move to.
|
||||
* @return void
|
||||
*/
|
||||
public function moveToStorage(string $storage): void
|
||||
{
|
||||
@@ -494,8 +481,6 @@ class Media extends Model
|
||||
|
||||
/**
|
||||
* Get the server maximum upload size
|
||||
*
|
||||
* @return integer
|
||||
*/
|
||||
public static function getMaxUploadSize(): int
|
||||
{
|
||||
@@ -620,7 +605,6 @@ class Media extends Model
|
||||
* Sanitize fileName for upload
|
||||
*
|
||||
* @param string $fileName Filename to sanitize.
|
||||
* @return string
|
||||
*/
|
||||
private static function sanitizeFilename(string $fileName): string
|
||||
{
|
||||
|
||||
@@ -24,8 +24,6 @@ class Permission extends Model
|
||||
|
||||
/**
|
||||
* Get the User associated with this model
|
||||
*
|
||||
* @return BelongsTo
|
||||
*/
|
||||
public function user(): BelongsTo
|
||||
{
|
||||
|
||||
@@ -79,8 +79,6 @@ class User extends Authenticatable implements Auditable
|
||||
|
||||
/**
|
||||
* Get the list of files of the user
|
||||
*
|
||||
* @return HasMany
|
||||
*/
|
||||
public function permissions(): HasMany
|
||||
{
|
||||
@@ -89,8 +87,6 @@ class User extends Authenticatable implements Auditable
|
||||
|
||||
/**
|
||||
* Get the permission attribute
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getPermissionsAttribute(): array
|
||||
{
|
||||
@@ -101,7 +97,6 @@ class User extends Authenticatable implements Auditable
|
||||
* Test if user has permission
|
||||
*
|
||||
* @param string $permission Permission to test.
|
||||
* @return boolean
|
||||
*/
|
||||
public function hasPermission(string $permission): bool
|
||||
{
|
||||
@@ -112,7 +107,6 @@ class User extends Authenticatable implements Auditable
|
||||
* Give permissions to the user
|
||||
*
|
||||
* @param string|array $permissions The permission(s) to give.
|
||||
* @return Collection
|
||||
*/
|
||||
public function givePermission($permissions): Collection
|
||||
{
|
||||
@@ -137,7 +131,6 @@ class User extends Authenticatable implements Auditable
|
||||
* Revoke permissions from the user
|
||||
*
|
||||
* @param string|array $permissions The permission(s) to revoke.
|
||||
* @return integer
|
||||
*/
|
||||
public function revokePermission($permissions): int
|
||||
{
|
||||
@@ -152,8 +145,6 @@ class User extends Authenticatable implements Auditable
|
||||
|
||||
/**
|
||||
* Get the list of files of the user
|
||||
*
|
||||
* @return HasMany
|
||||
*/
|
||||
public function media(): HasMany
|
||||
{
|
||||
@@ -162,8 +153,6 @@ class User extends Authenticatable implements Auditable
|
||||
|
||||
/**
|
||||
* Get the list of files of the user
|
||||
*
|
||||
* @return HasMany
|
||||
*/
|
||||
public function articles(): HasMany
|
||||
{
|
||||
@@ -172,8 +161,6 @@ class User extends Authenticatable implements Auditable
|
||||
|
||||
/**
|
||||
* Get associated user codes
|
||||
*
|
||||
* @return HasMany
|
||||
*/
|
||||
public function codes(): HasMany
|
||||
{
|
||||
@@ -182,8 +169,6 @@ class User extends Authenticatable implements Auditable
|
||||
|
||||
/**
|
||||
* Get the list of logins of the user
|
||||
*
|
||||
* @return HasMany
|
||||
*/
|
||||
public function logins(): HasMany
|
||||
{
|
||||
@@ -192,8 +177,6 @@ class User extends Authenticatable implements Auditable
|
||||
|
||||
/**
|
||||
* Get the events associated with the user.
|
||||
*
|
||||
* @return BelongsToMany
|
||||
*/
|
||||
public function events(): BelongsToMany
|
||||
{
|
||||
|
||||
@@ -23,8 +23,6 @@ class UserCode extends Model
|
||||
|
||||
/**
|
||||
* Boot function from Laravel.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
protected static function boot(): void
|
||||
{
|
||||
@@ -46,8 +44,6 @@ class UserCode extends Model
|
||||
|
||||
/**
|
||||
* Generate new code
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function regenerate(): void
|
||||
{
|
||||
@@ -62,8 +58,6 @@ class UserCode extends Model
|
||||
|
||||
/**
|
||||
* Clear expired user codes
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public static function clearExpired(): void
|
||||
{
|
||||
@@ -72,8 +66,6 @@ class UserCode extends Model
|
||||
|
||||
/**
|
||||
* Get associated user
|
||||
*
|
||||
* @return BelongsTo
|
||||
*/
|
||||
public function user(): BelongsTo
|
||||
{
|
||||
|
||||
@@ -28,8 +28,6 @@ class UserLogins extends Model
|
||||
|
||||
/**
|
||||
* Get the file user
|
||||
*
|
||||
* @return BelongsTo
|
||||
*/
|
||||
public function user(): BelongsTo
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user