Added validation for no inputs, fixed back button