More error checking added to Derpibooru script