# -*- coding: utf8 -*-

from __future__ import unicode_literals, absolute_import, print_function

from talos.services.base import ServiceBase
from talos.rpc import logging_exception


class AntiSpamService(ServiceBase):

    @classmethod
    def get_filtered_words(cls, filter_type=None):
        try:
            result = cls.call_rpc('api/filterWord/list', filter_type=filter_type)
        except Exception:
            logging_exception
            raise
        return result
