Fixed regex logic problem with equations
Repaired downloading image logic