mirror of
https://github.com/shlinkio/shlink.git
synced 2024-11-27 16:26:37 +03:00
Added migrations folder to the static analysis
This commit is contained in:
parent
27bc8d4823
commit
d99ea82761
3 changed files with 6 additions and 4 deletions
|
@ -109,7 +109,7 @@
|
||||||
],
|
],
|
||||||
"cs": "phpcs",
|
"cs": "phpcs",
|
||||||
"cs:fix": "phpcbf",
|
"cs:fix": "phpcbf",
|
||||||
"stan": "phpstan analyse module/*/src/ module/*/config config docker/config --level=6",
|
"stan": "phpstan analyse module/*/src/ module/*/config config docker/config data/migrations --level=6",
|
||||||
"test": [
|
"test": [
|
||||||
"@test:unit",
|
"@test:unit",
|
||||||
"@test:db",
|
"@test:db",
|
||||||
|
|
|
@ -24,10 +24,10 @@ class Version20171021093246 extends AbstractMigration
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
$shortUrls->addColumn('valid_since', Types::DATETIME, [
|
$shortUrls->addColumn('valid_since', Types::DATETIME_MUTABLE, [
|
||||||
'notnull' => false,
|
'notnull' => false,
|
||||||
]);
|
]);
|
||||||
$shortUrls->addColumn('valid_until', Types::DATETIME, [
|
$shortUrls->addColumn('valid_until', Types::DATETIME_MUTABLE, [
|
||||||
'notnull' => false,
|
'notnull' => false,
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
|
@ -46,7 +46,9 @@ final class Version20201102113208 extends AbstractMigration
|
||||||
'expiration' => Chronos::now()->toDateTimeString(),
|
'expiration' => Chronos::now()->toDateTimeString(),
|
||||||
]);
|
]);
|
||||||
|
|
||||||
$id = $this->resolveOneApiKeyId($qb->execute());
|
/** @var Result $result */
|
||||||
|
$result = $qb->execute();
|
||||||
|
$id = $this->resolveOneApiKeyId($result);
|
||||||
if ($id === null) {
|
if ($id === null) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue