Fix possible crash if arg is None
Fix possible crash if arg is None

Spotted on dispatcher03 where a bbb job
was left running and a traceback in the scheduler
logs showed that arg could be NoneType, causing
the replace to fail.

Change-Id: Ic105e58a37db0015e756e01d30f54a29e21f8067

Linaro/lava-server,Linaro/lava-server,Linaro/lava-server,Linaro/lava-server