Fix button active state bug