Use the correct length of the object

Mistake in previous commit, where the length of the object should be Object.keys(...).length,  the reporting were all broken :x