Modularize sessions controller