adding filter snippet