• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

codeigniter4 / shield / 13317939316

13 Feb 2025 10:03PM UTC coverage: 92.762%. First build
13317939316

Pull #1250

github

web-flow
Merge de6eeb646 into 58d6d6f88
Pull Request #1250: refactor: `display()` method to enhance readability and maintainability

11 of 11 new or added lines in 1 file covered. (100.0%)

2781 of 2998 relevant lines covered (92.76%)

147.01 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

66.67
/src/Authorization/AuthorizationException.php
1
<?php
2

3
declare(strict_types=1);
4

5
/**
6
 * This file is part of CodeIgniter Shield.
7
 *
8
 * (c) CodeIgniter Foundation <admin@codeigniter.com>
9
 *
10
 * For the full copyright and license information, please view
11
 * the LICENSE file that was distributed with this source code.
12
 */
13

14
namespace CodeIgniter\Shield\Authorization;
15

16
use CodeIgniter\Shield\Exceptions\RuntimeException;
17

18
class AuthorizationException extends RuntimeException
19
{
20
    protected $code = 401;
21

22
    public static function forUnknownGroup(string $group): self
23
    {
24
        return new self(lang('Auth.unknownGroup', [$group]));
6✔
25
    }
26

27
    public static function forUnknownPermission(string $permission): self
28
    {
29
        return new self(lang('Auth.unknownPermission', [$permission]));
6✔
30
    }
31

32
    public static function forUnauthorized(): self
33
    {
34
        return new self(lang('Auth.notEnoughPrivilege'));
×
35
    }
36
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc