Permalink
Browse files

fix annoying #/%23 bug of url.URL.

  • Loading branch information...
1 parent 21257d9 commit caf699f04238f4715c240b2bbf80d0d4818089d1 @akrennmair committed Jan 25, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 twitterapi.go
View
@@ -755,7 +755,7 @@ func (t *Tweet) RelativeCreatedAt() string {
func longify_url(url string) string {
if resp, err := http.Head(url); err == nil && resp.Request != nil && resp.Request.URL != nil {
- return resp.Request.URL.String()
+ return strings.Replace(resp.Request.URL.String(), "%23", "#", -1) // HACK, breaks real %23
}
return url
}

0 comments on commit caf699f

Please sign in to comment.