Fixed a bug giving wrong state, and made comparing version more efficient

combined the check for a multi-entry component into one block of code,
so there is less code and one less check for the 'version' key in the
JSON
deleted a file we dont need