Cleanup: Use centralized method for aptly detection

Fixes bug with empty node[apt]
Merge pull request #467 from fh/t/fix-nil

Cleanup: Use centralized method for aptly detection