Close #120: fix NullPointerException.