Fix ajax controller that would access ->last_visited when null