Check that args are present before mapping over

Closes #2925