Made a few changes works well now