Bugfixes and new compare criteria