various bug fixes after testing