checks for nested smart objects and...

… fix smart object type recognition in layer