Code Duplication    Length = 7-7 lines in 2 locations

core/admin/EE_Admin_Page.core.php 2 locations

@@ 788-794 (lines=7) @@
785
		if ( array_key_exists( $this->_req_action, $this->_page_routes )) {
786
			$this->_route = $this->_page_routes[ $this->_req_action ];
787
			$this->_route_config = isset($this->_page_config[$this->_req_action]) ? $this->_page_config[$this->_req_action] : array();
788
		} else {
789
			// user error msg
790
			$error_msg =  sprintf( __( 'The requested page route does not exist for the %s admin page.', 'event_espresso' ), $this->_admin_page_title );
791
			// developer error msg
792
			$error_msg .=  '||' . $error_msg . sprintf( __( ' Create a key in the "_page_routes" array named "%s" and set its value to the appropriate method.', 'event_espresso' ), $this->_req_action );
793
			throw new EE_Error( $error_msg );
794
		}
795
796
		// and that a default route exists
797
		if ( ! array_key_exists( 'default', $this->_page_routes )) {
@@ 831-837 (lines=7) @@
828
	protected function _verify_route( $route ) {
829
		if ( array_key_exists( $this->_req_action, $this->_page_routes )) {
830
			return true;
831
		} else {
832
			// user error msg
833
			$error_msg =  sprintf( __( 'The given page route does not exist for the %s admin page.', 'event_espresso' ), $this->_admin_page_title );
834
			// developer error msg
835
			$error_msg .=  '||' . $error_msg . sprintf( __( ' Check the route you are using in your method (%s) and make sure it matches a route set in your "_page_routes" array property', 'event_espresso' ), $route );
836
			throw new EE_Error( $error_msg );
837
		}
838
	}
839
840