fix graph codes etc