Correctly minifying images