# -*- Mode: Python; tab-width: 4 -*-

# This file controls filtering.
# It is reloaded by the SPAM RELOAD command.

import regex_filter
import blacklist_filter
import multi_filter

def build_filter():
	import regex_filter
	import convert_procmail_tag

	f1 = regex_filter.regex_filter (
		convert_procmail_tag.scan_tagfile (
			open ('./filter_data/tag.txt', 'r')
			)
		)

	# To add in the blacklist filter, uncomment the
	# following lines:

	#f2 = blacklist_filter.blacklist_filter (
	#	'filter_data/filter.cf.data'
	#	)

	#return multi_filter.multi_filter (f1, f2)

	return f1
