src/classes/CCRouter.php
public static function alias( $key, $to = null )
	{
		if ( is_null( $to ) || is_array( $to ) ) 
		{
			if ( array_key_exists( $key, static::$aliases ) )
			{
				if ( is_array( $to ) )
				{	
					// Workaround for HHVM: return preg_replace( "/\[\w+\]/e", 'array_shift($to)', static::$aliases[$key] );
					$return = static::$aliases[$key];
					
					foreach( $to as $rpl )
					{
						$return = preg_replace( "/\[\w+\]/", $rpl, $return, 1 );
					}
					
					return $return;
				}
				return static::$aliases[$key];
			}
			return false;
		}
		static::$aliases[$key] = $to;
	}
public static function alias( $key, $to = null )
	{
		if ( is_null( $to ) || is_array( $to ) ) 
		{
			if ( array_key_exists( $key, static::$aliases ) )
			{
				if ( is_array( $to ) )
				{	
					// Workaround for HHVM: return preg_replace( "/\[\w+\]/e", 'array_shift($to)', static::$aliases[$key] );
					$return = static::$aliases[$key];
					
					foreach( $to as $rpl )
					{
						$return = preg_replace( "/\[\w+\]/", $rpl, $return, 1 );
					}
					
					return $return;
				}
				return static::$aliases[$key];
			}
			return false;
		}
		static::$aliases[$key] = $to;
	}
public static function alias ( $ key , $ to = null ) { if ( is_null ( $ to ) || is_array ( $ to ) ) { if ( array_key_exists ( $ key , static :: $ aliases ) ) { if ( is_array ( $ to ) ) { // Workaround for HHVM: return preg_replace( "/\[\w+\]/e", 'array_shift($to)', static::$aliases[$key] ); $ return = static :: $ aliases [ $ key ] ; foreach ( $ to as $ rpl ) { $ return = preg_replace ( "/\[\w+\]/" , $ rpl , $ return , 1 ) ; } return $ return ; } return static :: $ aliases [ $ key ] ; } return false ; } static :: $ aliases [ $ key ] = $ to ; }
Creates an alias to a route or gets one

@param string			$key
@param string 		$to
@return void | false
Creates an alias to a route or gets one