Commit 6a519e9
authored
Replace gsub with rstrip (#1095)
The regular expression ``/\s*\z/`` matches any whitespace characters at end of string, which means only one match is possible with ``gsub``, replacing it with an empty string. The same can be achieved by ``String#rstrip``.1 parent e91b21f commit 6a519e9
1 file changed
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
159 | 159 | | |
160 | 160 | | |
161 | 161 | | |
162 | | - | |
| 162 | + | |
163 | 163 | | |
164 | 164 | | |
165 | 165 | | |
| |||
0 commit comments