Fixed casting BOOL issue, also fixed adding class vs. instance methods