fixed 2.0 compatibility issues (#161)