Skip to content

Commit

Permalink
Fix CS - do not import classes without namespace (#147)
Browse files Browse the repository at this point in the history
* Fix CS - do not import classes without namespace

* Apply fixes from StyleCI

Co-authored-by: Romans Malinovskis <[email protected]>
  • Loading branch information
mvorisek and romaninsh authored Apr 7, 2020
1 parent 882cf1c commit 7999f76
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
5 changes: 2 additions & 3 deletions src/Exception.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
use atk4\core\ExceptionRenderer\RendererAbstract;
use atk4\core\Translator\ITranslatorAdapter;
use atk4\core\Translator\Translator;
use Throwable;

/**
* All exceptions generated by Agile Core will use this class.
Expand Down Expand Up @@ -51,12 +50,12 @@ class Exception extends \Exception
*
* @param string|array $message
* @param int $code
* @param Throwable $previous
* @param \Throwable $previous
*/
public function __construct(
$message = '',
?int $code = null,
Throwable $previous = null
\Throwable $previous = null
) {
if (is_array($message)) {
// message contain additional parameters
Expand Down
3 changes: 1 addition & 2 deletions tests/ExceptionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
use atk4\core\Exception;
use atk4\core\TrackableTrait;
use PHPUnit\Framework\TestCase;
use StdClass;

/**
* @coversDefaultClass \atk4\core\Exception
Expand Down Expand Up @@ -63,7 +62,7 @@ public function testColorfulText(): void
$ret = $m->toString('abc');
$this->assertEquals('"abc"', $ret);

$ret = $m->toString(new StdClass());
$ret = $m->toString(new \stdClass());
$this->assertEquals('Object stdClass', $ret);

$a = new TrackableMock2();
Expand Down

0 comments on commit 7999f76

Please sign in to comment.