Skip to content

Commit

Permalink
Fixed missing enum dependency
Browse files Browse the repository at this point in the history
Used Taha Amin Ghafuri's (@tahaghafuri ) fork to replace the missing "cedx/enum" package with the "myclabs/php-enum" package
  • Loading branch information
mooror committed May 19, 2023
1 parent 714d079 commit 5deac6c
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 8 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"php": ">=7.2.0",
"ext-curl": "*",
"ext-json": "*",
"cedx/enum": "^7.4.0",
"myclabs/php-enum": "^1.8",
"guzzlehttp/guzzle": "~6.0"
},
"require-dev": {
Expand Down
10 changes: 6 additions & 4 deletions src/Model/StatusState.php
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
<?php declare(strict_types=1);
<?php

declare(strict_types=1);

namespace Gitea\Model;

use Enum\{EnumTrait};
use MyCLabs\Enum\Enum;

/** Defines the state of a Gitea status. */
final class StatusState {
use EnumTrait;
final class StatusState extends Enum {

/** @var string The status is an error. */
const error = 'error';
Expand Down
5 changes: 2 additions & 3 deletions src/Model/TeamPermission.php
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
<?php declare(strict_types=1);
namespace Gitea\Model;

use Enum\{EnumTrait};
use MyCLabs\Enum\Enum;

/** Defines the permission of a team. */
final class TeamPermission {
use EnumTrait;
final class TeamPermission extends Enum {

/** @var string The team has the administrator permission. */
const admin = 'admin';
Expand Down

0 comments on commit 5deac6c

Please sign in to comment.