Fix bug when only createdAt is enabled
Merge pull request #1543 from seegno/fix-created-at-bug

Fix bug when only createdAt is enabled