fix "Notice: Undefined property error" see #115