fixed errors in assembly refactor