fix goodbye problem and issue #1