Skip to content

Commit 6b2c009

Browse files
committed
Accomodate php-stan
1 parent fea3e7c commit 6b2c009

File tree

7 files changed

+13
-10
lines changed

7 files changed

+13
-10
lines changed

framework/Data/ActiveRecord/TActiveRecord.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -621,7 +621,7 @@ public function findAll($criteria = null, $parameters = [])
621621
* ```
622622
*
623623
* @param mixed $keys primary keys
624-
* @return null|TActiveRecord. Null if no result is found.
624+
* @return null|TActiveRecord Null if no result is found.
625625
*/
626626
public function findByPk($keys)
627627
{
@@ -667,7 +667,7 @@ public function findAllByPks($keys)
667667
* class.
668668
* @param string $sql select SQL
669669
* @param array $parameters
670-
* @return TActiveRecord, null if no result is returned.
670+
* @return TActiveRecord null if no result is returned.
671671
*/
672672
public function findBySql($sql, $parameters = [])
673673
{
@@ -732,7 +732,7 @@ public function count($criteria = null, $parameters = [])
732732
* value equal to the $property value.
733733
* @param string $name relationship/property name corresponding to keys in $RELATION array.
734734
* @param array $args method call arguments.
735-
* @return null|\Prado\Data\ActiveRecord\Relations\TActiveRecordRelation, null if the context or the handler doesn't exist
735+
* @return null|\Prado\Data\ActiveRecord\Relations\TActiveRecordRelation null if the context or the handler doesn't exist
736736
*/
737737
protected function getRelationHandler($name, $args = [])
738738
{

framework/Data/DataGateway/TDataGatewayCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ public function findAll($criteria)
132132
/**
133133
* Build the find command from the criteria. Limit, Offset and Ordering are applied if applicable.
134134
* @param TSqlCriteria $criteria $criteria
135-
* @return TDbCommand.
135+
* @return TDbCommand
136136
*/
137137
protected function getFindCommand($criteria)
138138
{

framework/TComponent.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -359,10 +359,10 @@
359359
* @method void dyWakeUp()
360360
* @method void dyListen(array $globalEvents)
361361
* @method void dyUnlisten(array $globalEvents)
362-
* @method string dyPreRaiseEvent(string $name, mixed $sender, \Prado\TEventParameter $param, null|numeric $responsetype, null|function $postfunction)
362+
* @method string dyPreRaiseEvent(string $name, mixed $sender, \Prado\TEventParameter $param, null|numeric $responsetype, null|callable $postfunction)
363363
* @method dyIntraRaiseEventTestHandler(callable $handler, mixed $sender, \Prado\TEventParameter $param, string $name)
364364
* @method bool dyIntraRaiseEventPostHandler(string $name, mixed $sender, \Prado\TEventParameter $param, callable $handler, $response)
365-
* @method array dyPostRaiseEvent(array $responses, string $name, mixed $sender, \Prado\TEventParameter $param, null|numeric $responsetype, null|function $postfunction)
365+
* @method array dyPostRaiseEvent(array $responses, string $name, mixed $sender, \Prado\TEventParameter $param, null|numeric $responsetype, null|callable $postfunction)
366366
* @method string dyEvaluateExpressionFilter(string $statements)
367367
* @method string dyEvaluateStatementsFilter(string $statements)
368368
* @method dyCreatedOnTemplate(\Prado\TComponent $parent)
@@ -1391,7 +1391,7 @@ public function detachEventHandler($name, $handler, $priority = false)
13911391
*
13921392
* Behaviors may implement the following functions with TBehaviors:
13931393
* ```php
1394-
* public function dyPreRaiseEvent($name, $sender, $param, $responsetype, $postfunction[, TCallChain $chain) {
1394+
* public function dyPreRaiseEvent($name, $sender, $param, $responsetype, $postfunction, TCallChain $chain) {
13951395
* .... // Your logic
13961396
* return $chain->dyPreRaiseEvent($name, $sender, $param, $responsetype, $postfunction); //eg, the event name may be filtered/changed
13971397
* }
@@ -1403,9 +1403,9 @@ public function detachEventHandler($name, $handler, $priority = false)
14031403
* .... // Your logic
14041404
* return $chain->dyIntraRaiseEventPostHandler($name, $sender, $param, $handler, $response); //contains the per handler response
14051405
* }
1406-
* public function dyPostRaiseEvent($responses, $name, $sender, $param,$ responsetype, $postfunction, TCallChain $chain) {
1406+
* public function dyPostRaiseEvent($responses, $name, $sender, $param, $responsetype, $postfunction, TCallChain $chain) {
14071407
* .... // Your logic
1408-
* return $chain->dyPostRaiseEvent($responses, $name, $sender, $param,$ responsetype, $postfunction);
1408+
* return $chain->dyPostRaiseEvent($responses, $name, $sender, $param, $responsetype, $postfunction);
14091409
* }
14101410
* ```
14111411
* to be executed when raiseEvent is called. The 'intra' dynamic events are called per handler in

framework/Util/Cron/TDbCronCleanLogTask.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ public function execute($cron)
5252
}
5353
} elseif (is_object($cron) && $cron->asa(TCronModule::SHELL_LOG_BEHAVIOR)) {
5454
/** @var TCronModule $cron */
55+
// @phpstan-ignore varTag.nativeType
5556
$cron->getOutputWriter()->writeLine("No DB Cron Module to clean", TShellWriter::RED);
5657
}
5758
}

framework/Web/Services/TFeedService.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,7 @@ public function run()
135135
// init feed properties
136136
foreach ($properties as $name => $value) {
137137
/** @var \Prado\TComponent $feed */
138+
// @phpstan-ignore varTag.nativeType
138139
$feed->setSubproperty($name, $value);
139140
}
140141
$feed->init($feedConfig);

framework/Web/UI/WebControls/TCheckBoxList.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
* @author Qiang Xue <[email protected]>
3636
* @since 3.0
3737
* @method TTableStyle getStyle()
38-
* @method TActiveControlAdapter getAdapter()
38+
* @method \Prado\Web\UI\ActiveControls\TActiveControlAdapter getAdapter()
3939
*/
4040
class TCheckBoxList extends TListControl implements IRepeatInfoUser, \Prado\Web\UI\INamingContainer, \Prado\Web\UI\IPostBackDataHandler, \Prado\Web\UI\IValidatable
4141
{

framework/Web/UI/WebControls/TTemplateColumn.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,7 @@ public function initializeCell($cell, $columnIndex, $itemType)
212212
}
213213
if ($control instanceof \Prado\IDataRenderer) {
214214
/** @var \Prado\TComponent $control */
215+
// @phpstan-ignore varTag.nativeType
215216
$control->attachEventHandler('OnDataBinding', [$this, 'dataBindColumn']);
216217
}
217218
} elseif ($template !== null) {

0 commit comments

Comments
 (0)