<?php

use BBRouter\RouteCollection as RouteCollection;
use RequestResponse\Response as Response;

RouteCollection::add("GET", '/', function() {
    global $OUTPUT;        
    $OUTPUT->load_view('wellcome');    
})->middleware_ignore('auth');

RouteCollection::add("GET", '/wellcome', function() {
    Response::json('This is an other wellcome message')->send();
})->middleware_ignore('auth');
