better handling if null value
unregister should return same value as unregister all files
Merge pull request #317 from daeks/315.1

better handling if null value