Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ProjectSchema doesn't return all properties #1493

Closed
eranelbaz opened this issue Jan 27, 2021 · 1 comment
Closed

ProjectSchema doesn't return all properties #1493

eranelbaz opened this issue Jan 27, 2021 · 1 comment
Milestone

Comments

@eranelbaz
Copy link

Description
By GitLab docs for Projects.all they return a lot of extra properties that aren't include in ProjectSchema object such as default_branch,
and if i want to get it i need to create something like that:

type ProjectSchemaCamelizedExtended = ProjectSchemaCamelized & { defaultBranch: string };
const projects = (await this.gitlabClient.Projects.all({ membership: true })) as ProjectSchemaCamelizedExtended[];

and only than I can use

projects.defaultBranch

because it isn't part of ProjectSchemaDefault or ProjectSchemaCamelized

Possible solutions
add the missing properties to the object

@jdalrymple
Copy link
Owner

Working on it right now in #1104

@jdalrymple jdalrymple added the bug label Jan 27, 2021
@jdalrymple jdalrymple linked a pull request Mar 5, 2021 that will close this issue
5 tasks
@jdalrymple jdalrymple added this to the next milestone Apr 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants