safer way to check for matrix job.