<?php
namespace Core;

class Redirect
{
	public static function to($url)
	{
		if($url)
		{
			$url = htmlspecialchars($url);

			header("Location:$url");
			return true;
		}
        throw new \Exception("Bad request", 400);
	}
}
