Fixing some state related problems
Redoing button enabling logic