corrects reference to side in Position.getCastlingRights