should now work with both .jpg and .jpeg files