Fix performance warning