adding methods, bug fixes