diff options
| author | Chris Price <chris@puppetlabs.com> | 2012-10-20 23:14:39 -0700 |
|---|---|---|
| committer | Chris Price <chris@puppetlabs.com> | 2012-10-20 23:14:39 -0700 |
| commit | f0d443fed02d870965613dd174793cc1816137a2 (patch) | |
| tree | 610b78ab10ae9cf0f495f71f743433ab9f11ea57 /git@cgit.fluxo.info:puppet-inifile | |
| parent | e517148f4a2ab309aeb8413095791b021574b417 (diff) | |
| download | puppet-inifile-f0d443fed02d870965613dd174793cc1816137a2.tar.gz puppet-inifile-f0d443fed02d870965613dd174793cc1816137a2.tar.bz2 | |
Refactor to clarify implementation of `save`
The `save` method was previously relying on some really
specific implementation details of the `section` class
(when the start/end_line would be nil, etc.). This made
the code a bit hard to follow.
This commit introduces a few utility methods in the
`section` class (`is_new_section?`, `is_global?`), and
refactors the `save` method to use them... this makes
the logic a little easier to follow and should hopefully
make it easier to maintain.
Diffstat (limited to 'git@cgit.fluxo.info:puppet-inifile')
0 files changed, 0 insertions, 0 deletions
