# How to customize / override topic guardian through a plugin

**URL:** https://meta.discourse.org/t/how-to-customize-override-topic-guardian-through-a-plugin/179739
**Category:** Development
**Created:** [February 15, 2021, 3:30am UTC](https://meta.discourse.org/t/how-to-customize-override-topic-guardian-through-a-plugin/179739 "2021-02-15T03:30:06Z")
**Posts on this page:** 1
**Showing post:** 5

<div class="post-metadata">

### Author: ![hyd504](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hyd504/32/177122_2.png) [@hyd504](https://meta.discourse.org/u/hyd504)
#### Post date: [February 15, 2021, 10:00pm UTC](https://meta.discourse.org/t/how-to-customize-override-topic-guardian-through-a-plugin/179739/5 "2021-02-15T22:00:17Z")

</div>

Okay. I think I found my answer. I just have to implement the “can\_create\_topic?” method in `module ::TopicGuardian` and it will automatically change TopicGuardian’s behavior without requiring to inject or registering it somewhere. Also, I can use super method inside my override method so that I don’t have to always manually keep it in sync with the original method in case that gets changed.

Got help from this topic: [Overriding user\_guardian.rb in a plugin (no fork necessary!)](https://meta.discourse.org/t/overriding-user-guardian-rb-in-a-plugin-no-fork-necessary/174839)

---

_[View the full topic](https://meta.discourse.org/t/how-to-customize-override-topic-guardian-through-a-plugin/179739)._
