Better typechecking in SessionController and Namespaces.