Fixed multiple history entries, fixes #338