move ros path into if