Code Duplication    Length = 8-10 lines in 2 locations

core/admin/contenus/GestionContenus.class.php 1 location

@@ 63-72 (lines=10) @@
60
61
62
		//-------------------------- GETTER ----------------------------------------------------------------------------//
63
		public function getParentTexte($parent) {
64
			$dbc = \core\App::getDb();
65
66
			$query = $dbc->query("SELECT titre FROM page WHERE ID_page=".$parent);
67
			if ((is_array($query)) && (count($query) > 0)) {
68
				foreach ($query as $obj) $this->parent_texte = $obj->titre;
69
			}
70
71
			return $this->parent_texte;
72
		}
73
		public function getErreur() {
74
			return $this->erreur;
75
		}

core/auth/Connexion.class.php 1 location

@@ 218-225 (lines=8) @@
215
		 * @param $id_identite
216
		 * @return mixed
217
		 */
218
		public static function getlastConnexion($id_identite) {
219
			$dbc = App::getDb();
220
221
			$query = $dbc->query("SELECT last_change_mdp FROM identite WHERE ID_identite=".$id_identite);
222
			if ((is_array($query)) && (count($query) > 0)) {
223
				foreach ($query as $obj) return $obj->last_change_mdp;
224
			}
225
		}
226
	}