filter out undefined replica