<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def discussion_is_still_open(self, discussion_type, auto_close_after):
 """ Checks if a type of discussion is still open are a certain number of days. """

        discussion_enabled = getattr(self, discussion_type)
        if (discussion_enabled and isinstance(auto_close_after, int) and
                auto_close_after >= 0):
            return (timezone.now() - (
                self.start_publication or self.publication_date)).days < \
                auto_close_after
        return discussion_enabled