Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
enjinabner committed Jun 26, 2024
1 parent a4c6893 commit 63c838e
Show file tree
Hide file tree
Showing 33 changed files with 97 additions and 34 deletions.
4 changes: 3 additions & 1 deletion src/Events/BeamClaimInProgress.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@

namespace Enjin\Platform\Beam\Events;

class BeamClaimInProgress extends BeamClaimPending {}
class BeamClaimInProgress extends BeamClaimPending
{
}
4 changes: 3 additions & 1 deletion src/Events/BeamClaimsComplete.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@

namespace Enjin\Platform\Beam\Events;

class BeamClaimsComplete extends BeamClaimPending {}
class BeamClaimsComplete extends BeamClaimPending
{
}
4 changes: 3 additions & 1 deletion src/Events/BeamClaimsFailed.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@

namespace Enjin\Platform\Beam\Events;

class BeamClaimsFailed extends BeamClaimPending {}
class BeamClaimsFailed extends BeamClaimPending
{
}
4 changes: 3 additions & 1 deletion src/Events/BeamDeleted.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@

namespace Enjin\Platform\Beam\Events;

class BeamDeleted extends BeamCreated {}
class BeamDeleted extends BeamCreated
{
}
4 changes: 3 additions & 1 deletion src/Events/BeamUpdated.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@

namespace Enjin\Platform\Beam\Events;

class BeamUpdated extends BeamCreated {}
class BeamUpdated extends BeamCreated
{
}
4 changes: 3 additions & 1 deletion src/Events/TokensRemoved.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,6 @@

namespace Enjin\Platform\Beam\Events;

class TokensRemoved extends TokensAdded {}
class TokensRemoved extends TokensAdded
{
}
4 changes: 3 additions & 1 deletion src/Jobs/ClaimBeam.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ class ClaimBeam implements ShouldQueue
/**
* Create a new job instance.
*/
public function __construct(protected ?array $data) {}
public function __construct(protected ?array $data)
{
}

/**
* Execute the job.
Expand Down
4 changes: 3 additions & 1 deletion src/Jobs/CreateBeamClaims.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@ class CreateBeamClaims implements ShouldQueue
/**
* Create a new job instance.
*/
public function __construct(protected ?Collection $chunk) {}
public function __construct(protected ?Collection $chunk)
{
}

/**
* Execute the job.
Expand Down
4 changes: 3 additions & 1 deletion src/Jobs/CreateClaim.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@ class CreateClaim implements ShouldQueue
/**
* Create a new job instance.
*/
public function __construct(protected ?array $claim) {}
public function __construct(protected ?array $claim)
{
}

/**
* Execute the job.
Expand Down
3 changes: 2 additions & 1 deletion src/Jobs/DispatchCreateBeamClaimsJobs.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ class DispatchCreateBeamClaimsJobs implements ShouldQueue
public function __construct(
protected Model $beam,
protected ?array $tokens
) {}
) {
}

/**
* Execute the job.
Expand Down
4 changes: 3 additions & 1 deletion src/Listeners/UpdateClaimCollectionIds.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@

class UpdateClaimCollectionIds implements ShouldQueue
{
public function __construct(private readonly BeamClaimService $beamClaimService) {}
public function __construct(private readonly BeamClaimService $beamClaimService)
{
}

/**
* Handle the event.
Expand Down
4 changes: 3 additions & 1 deletion src/Listeners/UpdateClaimStatus.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ class UpdateClaimStatus implements ShouldQueue
/**
* Create new event listener instance.
*/
public function __construct() {}
public function __construct()
{
}

/**
* Handle the event.
Expand Down
4 changes: 3 additions & 1 deletion src/Models/Beam.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,6 @@

use Enjin\Platform\Models\ModelResolver;

class Beam extends ModelResolver {}
class Beam extends ModelResolver
{
}
4 changes: 3 additions & 1 deletion src/Models/BeamBatch.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,6 @@

use Enjin\Platform\Models\ModelResolver;

class BeamBatch extends ModelResolver {}
class BeamBatch extends ModelResolver
{
}
4 changes: 3 additions & 1 deletion src/Models/BeamClaim.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,6 @@

use Enjin\Platform\Models\ModelResolver;

class BeamClaim extends ModelResolver {}
class BeamClaim extends ModelResolver
{
}
4 changes: 3 additions & 1 deletion src/Models/BeamScan.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,6 @@

use Enjin\Platform\Models\ModelResolver;

class BeamScan extends ModelResolver {}
class BeamScan extends ModelResolver
{
}
6 changes: 4 additions & 2 deletions src/Rules/BeamExists.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@

class BeamExists implements ValidationRule
{
public function __construct(protected string $column = 'code') {}
public function __construct(protected string $column = 'code')
{
}

/**
* Run the validation rule.
Expand All @@ -22,7 +24,7 @@ public function validate(string $attribute, mixed $value, Closure $fail): void
$value = $beamData->beamCode;
}

if (! Beam::where($this->column, $value)->exists()) {
if (!Beam::where($this->column, $value)->exists()) {
$fail('validation.exists')->translate();
}
}
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/CanClaim.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@ class CanClaim implements DataAwareRule, ValidationRule
/**
* Create new rule instance.
*/
public function __construct(protected bool $singleUse = false) {}
public function __construct(protected bool $singleUse = false)
{
}

/**
* Determine if the validation rule passes.
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/HasBeamFlag.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,9 @@ class HasBeamFlag implements ValidationRule
/**
* Create new rule instance.
*/
public function __construct(protected BeamFlag $flag) {}
public function __construct(protected BeamFlag $flag)
{
}

/**
* Determine if the validation rule passes.
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/MaxTokenCount.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@ class MaxTokenCount implements DataAwareRule, ValidationRule
*/
protected $limit;

public function __construct(protected ?string $collectionId) {}
public function __construct(protected ?string $collectionId)
{
}

/**
* Determine if the validation rule passes.
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/MaxTokenSupply.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,9 @@ class MaxTokenSupply implements DataAwareRule, ValidationRule
/**
* Create instance of rule.
*/
public function __construct(protected ?string $collectionId) {}
public function __construct(protected ?string $collectionId)
{
}

/**
* Determine if the validation rule passes.
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/NotExpired.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@

class NotExpired implements ValidationRule
{
public function __construct(protected ?string $code = null) {}
public function __construct(protected ?string $code = null)
{
}

/**
* Determine if the validation rule passes.
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/NotOwner.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ class NotOwner implements DataAwareRule, ValidationRule
{
use HasDataAwareRule;

public function __construct(protected bool $isSingleUse = false) {}
public function __construct(protected bool $isSingleUse = false)
{
}

/**
* Determine if the validation rule passes.
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/NotPaused.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@

class NotPaused implements ValidationRule
{
public function __construct(protected ?string $code = null) {}
public function __construct(protected ?string $code = null)
{
}

/**
* Determine if the validation rule passes.
Expand Down
3 changes: 2 additions & 1 deletion src/Rules/PassesClaimCondition.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ class PassesClaimCondition implements DataAwareRule, ValidationRule
public function __construct(
protected Closure $function,
protected bool $singleUse
) {}
) {
}

/**
* Determine if the validation rule passes.
Expand Down
3 changes: 2 additions & 1 deletion src/Rules/PassesClaimConditions.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ class PassesClaimConditions implements DataAwareRule, ValidationRule
*/
public function __construct(
protected bool $singleUse
) {}
) {
}

public static function addConditionalFunctions(Closure|array|Collection $functions): void
{
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/SingleUseCodeExist.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@

class SingleUseCodeExist implements ValidationRule
{
public function __construct(protected bool $isClaiming = false) {}
public function __construct(protected bool $isClaiming = false)
{
}

/**
* Determine if the validation rule passes.
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/TokenUploadExistInCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ class TokenUploadExistInCollection implements ValidationRule
*/
protected $message;

public function __construct(protected ?string $collectionId) {}
public function __construct(protected ?string $collectionId)
{
}

/**
* Determine if the validation rule passes.
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/TokenUploadNotExistInBeam.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ class TokenUploadNotExistInBeam implements DataAwareRule, ValidationRule
use IntegerRange;
use HasDataAwareRule;

public function __construct(protected ?Model $beam = null) {}
public function __construct(protected ?Model $beam = null)
{
}

/**
* Determine if the validation rule passes.
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/TokenUploadNotExistInCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,9 @@ class TokenUploadNotExistInCollection implements ValidationRule
{
use IntegerRange;

public function __construct(protected ?string $collectionId) {}
public function __construct(protected ?string $collectionId)
{
}

/**
* Determine if the validation rule passes.
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/TokensDoNotExistInBeam.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ class TokensDoNotExistInBeam implements DataAwareRule, ValidationRule
use IntegerRange;
use HasDataAwareRule;

public function __construct(protected ?Model $beam = null) {}
public function __construct(protected ?Model $beam = null)
{
}

/**
* Determine if the validation rule passes.
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/TokensDoNotExistInCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@ class TokensDoNotExistInCollection implements ValidationRule
{
use IntegerRange;

public function __construct(protected ?string $collectionId) {}
public function __construct(protected ?string $collectionId)
{
}

/**
* Determine if the validation rule passes.
Expand Down
4 changes: 3 additions & 1 deletion src/Rules/TokensExistInCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@ class TokensExistInCollection implements ValidationRule
{
use IntegerRange;

public function __construct(protected ?string $collectionId) {}
public function __construct(protected ?string $collectionId)
{
}

/**
* Determine if the validation rule passes.
Expand Down

0 comments on commit 63c838e

Please sign in to comment.