<?php

namespace app\controllers;

use app\models\Anime;

class AnimeController extends \lithium\action\Controller {
	public $publicActions = array('view');

	public function view($id = null)
	{
		if (is_numeric($id)) {
			return Anime::search($id, null, 'special_id');
		}
		else {
			return $this->redirect(array('controller' => 'search','q' => array('search' => $id)));
		}
	
	}
}	