Code Duplication    Length = 7-9 lines in 2 locations

lib/Service/BoardService.php 1 location

@@ 347-355 (lines=9) @@
344
	 * @throws \OCP\AppFramework\Db\MultipleObjectsReturnedException
345
	 * @throws BadRequestException
346
	 */
347
	public function deleteForce($id) {
348
		if (is_numeric($id) === false)  {
349
			throw new BadRequestException('id must be a number');
350
		}
351
352
		$this->permissionService->checkPermission($this->boardMapper, $id, Acl::PERMISSION_READ);
353
		$board = $this->find($id);
354
		return $this->boardMapper->delete($board);
355
	}
356
357
	/**
358
	 * @param $id

lib/Service/LabelService.php 1 location

@@ 60-66 (lines=7) @@
57
	 * @throws \OCP\AppFramework\Db\MultipleObjectsReturnedException
58
	 * @throws BadRequestException
59
	 */
60
	public function find($labelId) {
61
		if (is_numeric($labelId) === false) {
62
			throw new BadRequestException('label id must be a number');
63
		}
64
		$this->permissionService->checkPermission($this->labelMapper, $labelId, Acl::PERMISSION_READ);
65
		return $this->labelMapper->find($labelId);
66
	}
67
68
	/**
69
	 * @param $title