Made REST API uri parser thing slightly less stupid