# What is "reloadable\_patch" exactly?

**URL:** <https://meta.discourse.org/t/what-is-reloadable-patch-exactly/160247>\
**Category:** Development\
**Created:** [August 9, 2020, 11:40am UTC](https://meta.discourse.org/t/what-is-reloadable-patch-exactly/160247 "2020-08-09T11:40:00Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![neounix](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/neounix/32/215617_2.png) [@neounix](https://meta.discourse.org/u/neounix)\
**Post date:** [August 9, 2020, 11:40am UTC](https://meta.discourse.org/t/what-is-reloadable-patch-exactly/160247/1 "2020-08-09T11:40:00Z")

</div>

Hey,

Still trying to dissect plugins, I was looking to override `TopicsController` in my studies and searched the Discourse code repo and noticed `reloadable_patch`

Then I searched for `reloadable_patch` in Discourse, and got 12 code hits:

> **[Build software better, together](https://github.com/search?p=1&q=org%3Adiscourse+reloadable_patch&type=Code)**
>
> GitHub is where people build software. More than 150 million people use GitHub to discover, fork, and contribute to over 420 million projects.

So, I decided to look more broadly to try to understand this fascinating “method / hook (?)”, so I:

- Searched all of Github:  
– All results seem to be related to Discourse (plugins)

- Searched the web  
– All results seem to be related to Discourse (plugins)

- Searched meta  
– Got a few hits but nothing which explained `reloadable_patch` (internals) in details.

Next, I searched the Discourse repo again, and could not find (must be because I am not experienced at this) the “definition” of what, exactly `reloadable_patch` does (or is defined).

It seems, to a Ruby rookie like me, to be a “method” for a lack of a better word, or a “hook” that facilitates overriding Discourse classes; but I could not find the Ruby code which defines how it works, internally.

Does someone mind to explain this to me or point me to the “defining code” which would explain what `reloadable_patch` does, from a Ruby internals perspective?

Thanks!

Hopefully, I’m not being a PITA to ask !! 🙂

---

_[View the full topic](https://meta.discourse.org/t/what-is-reloadable-patch-exactly/160247)._
