add methods to fix issue #1