Code refactoring is a practice of software engineering that address maintainability. The effect (or the goal - if it is only this one) to produce more readable code is not secondary to increased stability and consistency to a predetermined (or evolving) paradigm.
Change the internal structure of a well-identified portion of code may not affect the functionality of it. If the modification is not explicitly evolutionary, your gain is (as said before) maintainability / readability: this should not be underestimated because it means that this piece of code will be more inclined to change and extensibility.
All this can be donewithout the worry of worsening the code or allow the resurface of solved issuesif there is a good unit tests coverage.
Refactoring is essential in any software, but in an open source project the high complexity of the code, the one regarding the neglect of the objective of legibility, will keep away potential contributors. Nevertheless, if your project is targetedprimarily to developers: complex code (or code indecipherable unless interspersed with many lines of comments) will prevent the adoption by the latter.
For example you might notice how the refactoring has evolved a core part of a open source project of my creation (the one when I can spend more time at the moment): Command Line Parser Library. Who loves to study things in detail (like me) can analyze the evolution of the following types from version 22.214.171.124 alfa to version 126.96.36.199 beta.