Added a check that I somehow missed before