Switched return statements to using bitops instead of ternary statements, ternary statements considered harmful