Skip to content

Commit

Permalink
fix: minor space in tweet
Browse files Browse the repository at this point in the history
  • Loading branch information
Ezequiel Olea Figueroa committed May 13, 2023
1 parent 0849781 commit 92a588e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion provider/github/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ func (p Provider) getContent(repo *github.Repository) *domain.Content {
}

if repo.UpdatedAt != nil {
lastUpdatedAt := "Updated on : " + repo.GetUpdatedAt().Format("2006-01-02")
lastUpdatedAt := fmt.Sprintf("Updated on: %s", repo.GetUpdatedAt().Format("2006-01-02"))
c.ExtraData = append(c.ExtraData, lastUpdatedAt)
}

Expand Down
4 changes: 2 additions & 2 deletions provider/github/provider_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ func TestGetContent(t *testing.T) {
Name: "Test no repo data with only updated at",
mockConfig: config.Config{},
repo: &github.Repository{Language: &lang, HTMLURL: &url, UpdatedAt: &github.Timestamp{Time: updatedAt}},
returnValue: &domain.Content{URL: &url, ExtraData: []string{"Updated on : 2000-07-12", "#g "}},
returnValue: &domain.Content{URL: &url, ExtraData: []string{"Updated on: 2000-07-12", "#g "}},
},
{
Name: "Test full with username",
Expand All @@ -285,7 +285,7 @@ func TestGetContent(t *testing.T) {
},
},
repo: &github.Repository{Name: &name, Description: &desc, Language: &lang, HTMLURL: &url, StargazersCount: &count, Owner: &gu, UpdatedAt: &github.Timestamp{Time: updatedAt}},
returnValue: &domain.Content{Title: &name, Subtitle: &desc, URL: &url, ExtraData: []string{"Lang: g", "⭐️ 1", "Author: @twitterusername", "Updated on : 2000-07-12", "#g "}},
returnValue: &domain.Content{Title: &name, Subtitle: &desc, URL: &url, ExtraData: []string{"Lang: g", "⭐️ 1", "Author: @twitterusername", "Updated on: 2000-07-12", "#g "}},
},
} {
t.Run(tc.Name, func(t *testing.T) {
Expand Down

0 comments on commit 92a588e

Please sign in to comment.