updates, made some slight changes to public api