Code Duplication    Length = 8-11 lines in 2 locations

application/models/Tracker_Model.php 2 locations

@@ 269-279 (lines=11) @@
266
		return  $success;
267
	}
268
269
	public function deleteTrackerByID(int $userID, int $chapterID) {
270
		//Series are not fully deleted, they are just marked as inactive as to hide them from the user.
271
		//This is to allow user history to function properly.
272
273
		$success = $this->db->set(['active' => 'N', 'last_updated' => NULL])
274
		                    ->where('user_id', $userID)
275
		                    ->where('id', $chapterID)
276
		                    ->update('tracker_chapters');
277
278
		return (bool) $success;
279
	}
280
	private function updateTitleById(int $id, string $latestChapter) {
281
		//FIXME: Really not too happy with how we're doing history stuff here, it just feels messy.
282
		$query = $this->db->select('latest_chapter AS current_chapter')
@@ 477-484 (lines=8) @@
474
475
		return $status;
476
	}
477
	public function setCategoryTrackerByID(int $userID, int $chapterID, string $category) : bool {
478
		$success = $this->db->set(['category' => $category, 'active' => 'Y', 'last_updated' => NULL])
479
		                    ->where('user_id', $userID)
480
		                    ->where('id', $chapterID)
481
		                    ->update('tracker_chapters');
482
483
		return (bool) $success;
484
	}
485
486
487
	public function updateTagsByID(int $userID, int $chapterID, string $tag_string) : bool {