several cleanups and renamings