better error handling in projecting coordinates using m.proj