updated and cleanup