memory issue mostly fixed

found cause of memory issue. need to clean up a little