fix bug in shard support