Browse Source

fix RepositoryListByOrgOptions in README sample

RepositoryListByOrgOptions doesn't have a `Sort` field
dmnlk 11 years ago
committed by Will Norris
parent
commit
31ecb2cc3f
1 changed files with 2 additions and 3 deletions
  1. +2
    -3
      README.md

+ 2
- 3
README.md View File

@ -25,12 +25,11 @@ orgs, _, err := client.Organizations.List("willnorris", nil)
```
Some API methods have optional parameters that can be passed. For example,
to list repositories for the "github" organization, sorted by the time they
were last updated:
to list public repositories for the "github" organization:
```go
client := github.NewClient(nil)
opt := &github.RepositoryListByOrgOptions{Sort: "updated"}
opt := &github.RepositoryListByOrgOptions{Type: "public"}
repos, _, err := client.Repositories.ListByOrg("github", opt)
```


Loading…
Cancel
Save