sforkowany z mirror/social
removing useless getLastInsertId()
rodzic
b534b11664
commit
e644ec335c
|
@ -62,10 +62,8 @@ class CacheActorsRequest extends CacheActorsRequestBuilder {
|
|||
* insert cache about an Actor in database.
|
||||
*
|
||||
* @param Person $actor
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function save(Person $actor): int {
|
||||
public function save(Person $actor) {
|
||||
$qb = $this->getCacheActorsInsertSql();
|
||||
$qb->setValue('id', $qb->createNamedParameter($actor->getId()))
|
||||
->setValue('account', $qb->createNamedParameter($actor->getAccount()))
|
||||
|
@ -101,8 +99,6 @@ class CacheActorsRequest extends CacheActorsRequestBuilder {
|
|||
$qb->setValue('icon_id', $qb->createNamedParameter($iconId));
|
||||
|
||||
$qb->execute();
|
||||
|
||||
return $qb->getLastInsertId();
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -61,10 +61,8 @@ class NotesRequest extends NotesRequestBuilder {
|
|||
* Insert a new Note in the database.
|
||||
*
|
||||
* @param Note $note
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
public function save(Note $note): int {
|
||||
public function save(Note $note) {
|
||||
$dTime = new DateTime();
|
||||
$dTime->setTimestamp($note->getPublishedTime());
|
||||
|
||||
|
@ -108,8 +106,6 @@ class NotesRequest extends NotesRequestBuilder {
|
|||
);
|
||||
|
||||
$qb->execute();
|
||||
|
||||
return $qb->getLastInsertId();
|
||||
}
|
||||
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue