Skip to content

Commit

Permalink
Add strict union (array|bool) type declaration
Browse files Browse the repository at this point in the history
  • Loading branch information
pH-7 committed Jan 3, 2023
1 parent 92c04dd commit 870494d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions _protected/app/system/core/models/UpgradeCoreModel.php
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
<?php
/**
* @author Pierre-Henry Soria <hello@ph7builder.com>
* @copyright (c) 2012-2019, Pierre-Henry Soria. All Rights Reserved.
* @copyright (c) 2012-2023, Pierre-Henry Soria. All Rights Reserved.
* @license MIT License; See LICENSE.md and COPYRIGHT.md in the root directory.
* @package PH7 / App / System / Core / Model
*/

declare(strict_types=1);

namespace PH7;

use PH7\Framework\Mvc\Model\Engine\Model;
Expand All @@ -20,7 +22,7 @@ class UpgradeCoreModel extends Model
*
* @return bool|array Returns TRUE if there are no errors, otherwise returns an ARRAY of error information.
*/
public function run($sSqlUpgradeFile)
public function run(string $sSqlUpgradeFile): bool|array
{
return Various::execQueryFile($sSqlUpgradeFile);
}
Expand Down

0 comments on commit 870494d

Please sign in to comment.