Fix some redundant casts

Happier psalm

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
Roeland Jago Douma 2021-03-08 08:51:08 +01:00
parent e148a151c1
commit 69b26c73f3
3 changed files with 3 additions and 7 deletions

View File

@ -393,9 +393,7 @@ class FederatedShareProvider implements IShareProvider {
$qb->setValue('file_target', $qb->createNamedParameter(''));
$qb->execute();
$id = $qb->getLastInsertId();
return (int)$id;
return $qb->getLastInsertId();
}
/**

View File

@ -690,9 +690,7 @@ class ShareByMailProvider implements IShareProvider {
$qb->setValue('file_target', $qb->createNamedParameter(''));
$qb->execute();
$id = $qb->getLastInsertId();
return (int)$id;
return $qb->getLastInsertId();
}
/**

View File

@ -136,7 +136,7 @@ abstract class QBMapper {
if ($entity->id === null) {
// When autoincrement is used id is always an int
$entity->setId((int)$qb->getLastInsertId());
$entity->setId($qb->getLastInsertId());
}
return $entity;