| Total Complexity | 3 |
| Total Lines | 23 |
| Duplicated Lines | 0 % |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php declare(strict_types=1); |
||
| 22 | class PodcastChannelMapper extends BaseMapper { |
||
| 23 | public function __construct(IDBConnection $db) { |
||
| 25 | } |
||
| 26 | |||
| 27 | /** |
||
| 28 | * @return int[] |
||
| 29 | */ |
||
| 30 | public function findAllIdsWithNoUpdateSince(string $userId, \DateTime $timeLimit) : array { |
||
| 31 | $sql = "SELECT `id` FROM `{$this->getTableName()}` WHERE `user_id` = ? AND `update_checked` < ?"; |
||
| 32 | $result = $this->execute($sql, [$userId, $timeLimit->format(BaseMapper::SQL_DATE_FORMAT)]); |
||
| 33 | |||
| 34 | return \array_map('intval', $result->fetchAll(\PDO::FETCH_COLUMN)); |
||
| 35 | } |
||
| 36 | |||
| 37 | /** |
||
| 38 | * @see \OCA\Music\Db\BaseMapper::findUniqueEntity() |
||
| 39 | * @param PodcastChannel $channel |
||
| 40 | * @return PodcastChannel |
||
| 41 | */ |
||
| 42 | protected function findUniqueEntity(Entity $channel) : Entity { |
||
| 45 | } |
||
| 46 | } |
||
| 47 |