Replaced the outdated method setVar to set
change deprecated method
Merge pull request #253 from iljaSuhinin/fix_image_type

Replaced the outdated method setVar to set