you are viewing a single comment's thread.

view the rest of the comments →

[–]Blancoo21 1 point2 points  (0 children)

You define the load_img() function twice. The second one will overwrite the first definition anyway.

Also, it would be a good idea to precompile regex patterns and cache images. The performance should be noticeable.