Fix spaceships

Then collector returns nothing we will end up with
null Class evaluation error. To fix it, use if defined().

Closes-bug: #1353340

Change-Id: Ic329bdd6ae7c91ef693263f5b84d1f0910ca962b
Signed-off-by: Bogdan Dobrelya <bdobrelia@mirantis.com>