Fix a bug with multiple empty DOM nodes

Issue #8: https://github.com/oo12/imageSlim/issues/8