OOIION-1654: Fixed cleanup of duplicate directory keys
Merge pull request #440 from mmeisinger/fix1654_dir_r2

OOIION-1654: Fixed cleanup of duplicate directory keys