changed priority function call to Manhattan priority function