Fix ordering bug with key prefixes in LevelDB.