Fix SQL checking if player belongs to a faction