Skip to content

Commit

Permalink
[BUG] Fix #215
Browse files Browse the repository at this point in the history
  • Loading branch information
qiuyuzhou committed Jan 20, 2017
1 parent c28be01 commit e481860
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion ShadowsocksX-NG/ServerProfile.swift
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,8 @@ class ServerProfile: NSObject, NSCopying {
guard let decoded = String(data: data, encoding: String.Encoding.utf8) else {
return nil
}
return "ss://\(decoded)"
let s = decoded.trimmingCharacters(in: CharacterSet(charactersIn: "\n"))
return "ss://\(s)"
}

guard let decodedUrl = decodeUrl(url: url) else {
Expand Down

0 comments on commit e481860

Please sign in to comment.