More ORM-changes. Count-plugin implemented.