Fixed a bug in detect script (had extra spaces in the if statement)

Change-Id: I9626f32f608d7318a7d28cad53ce883058e2816a