Potential fix for #8
Merge branch 'master' into image-state-fix