mirror of
https://github.com/goodhosts/hostsfile.git
synced 2026-04-27 15:35:50 +03:00
[GH-ISSUE #8] Comments are not published on Flush #3
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/hostsfile#3
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @ShivalikRanaut on GitHub (Jun 8, 2020).
Original GitHub issue: https://github.com/goodhosts/hostsfile/issues/8
Hi with the new update , Comments are not published
func (l *HostsLine) ToRaw() string {var comment string
if l.Comment != "" {
comment = fmt.Sprintf(" %s%s", commentChar, l.Comment)
}
}`
can be changed to
`func (l *HostsLine) ToRaw() string {
if l.IsComment() {
return l
}
var comment string
if l.Comment != "" {
comment = fmt.Sprintf(" %s%s", commentChar, l.Comment)
}
}`
@ShivalikRanaut commented on GitHub (Jun 8, 2020):
I have added a pull request for the same https://github.com/goodhosts/hostsfile/pull/9/commits