Code Duplication    Length = 10-11 lines in 2 locations

www/engine/System/Classes/Modules/Informer/Informer.php 1 location

@@ 11-21 (lines=11) @@
8
9
		# Count table entries
10
11
		public static function countEntries(string $table, bool $false_on_error = false) {
12
13
			if (!(DB::select($table, 'COUNT(id) as count') && (DB::getLast()->rows === 1))) {
14
15
				return (!$false_on_error ? 0 : false);
16
			}
17
18
			# ------------------------
19
20
			return intval(DB::getLast()->getRow()['count']);
21
		}
22
23
		# Check if install file exists
24

www/engine/System/Classes/Modules/Tools/Handler/Sitemap.php 1 location

@@ 11-20 (lines=10) @@
8
9
		# Get last modified
10
11
		private function getLastModified() {
12
13
			$selection = 'MAX(time_modified) as last_modified';
14
15
			if (!(DB::select(TABLE_PAGES, $selection) && (DB::getLast()->rows === 1))) return 0;
16
17
			# ------------------------
18
19
			return intval(DB::getLast()->getRow()['last_modified']);
20
		}
21
22
		# Get pages
23