Skip to content

Commit

Permalink
Merge pull request #93 from niden/master
Browse files Browse the repository at this point in the history
v5.3.1
  • Loading branch information
niden authored Sep 12, 2023
2 parents 70eab3c + f049bea commit ec3c12f
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 6 deletions.
19 changes: 17 additions & 2 deletions src/Mvc/Model.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@
use Phalcon\Mvc\Model\ValidationFailed;
use Phalcon\Mvc\ModelInterface;
use Phalcon\Filter\Validation\ValidationInterface;
use Phalcon\Support\Collection;
use Phalcon\Support\Collection\CollectionInterface;
use Serializable;

/**
Expand Down Expand Up @@ -1294,6 +1296,17 @@ public function save(): bool
{
}

/**
* Inserted or updates model instance, expects a visited list of objects.
*
* @param CollectionInterface $visited
*
* @return bool
*/
public function doSave(\Phalcon\Support\Collection\CollectionInterface $visited): bool
{
}

/**
* Serializes the object ignoring connections, services, related objects or
* static properties
Expand Down Expand Up @@ -1673,10 +1686,11 @@ protected function preSave(\Phalcon\Mvc\Model\MetaDataInterface $metaData, bool
* Saves related records that must be stored prior to save the master record
*
* @param ModelInterface[] $related
* @param CollectionInterface $visited
* @return bool
* @param \Phalcon\Db\Adapter\AdapterInterface $connection
*/
protected function preSaveRelatedRecords(\Phalcon\Db\Adapter\AdapterInterface $connection, $related): bool
protected function preSaveRelatedRecords(\Phalcon\Db\Adapter\AdapterInterface $connection, $related, \Phalcon\Support\Collection\CollectionInterface $visited): bool
{
}

Expand All @@ -1695,10 +1709,11 @@ protected function postSave(bool $success, bool $exists): bool
* Save the related records assigned in the has-one/has-many relations
*
* @param ModelInterface[] $related
* @param CollectionInterface $visited
* @return bool
* @param \Phalcon\Db\Adapter\AdapterInterface $connection
*/
protected function postSaveRelatedRecords(\Phalcon\Db\Adapter\AdapterInterface $connection, $related): bool
protected function postSaveRelatedRecords(\Phalcon\Db\Adapter\AdapterInterface $connection, $related, \Phalcon\Support\Collection\CollectionInterface $visited): bool
{
}

Expand Down
8 changes: 4 additions & 4 deletions src/Mvc/Router/Route.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@ class Route implements \Phalcon\Mvc\Router\RouteInterface
protected $hostname = null;

/**
* @var string|null
* @var string
*/
protected $id = null;
protected $id = '';

/**
* @var array|string
Expand Down Expand Up @@ -204,9 +204,9 @@ public function getHostname(): ?string
}

/**
* @return string | null
* @return string
*/
public function getId(): ?string
public function getId(): string
{
}

Expand Down

0 comments on commit ec3c12f

Please sign in to comment.