fix syntax error to save hops to file