Fixed potion optimization check