Just added minor changes to port to code to another place