Done issue #152 + fix bug