Making changes for threading etc