fix if statement in FlashWS.ready method