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

Too many undefined values in API client #70

Open
FelixTJDietrich opened this issue Sep 2, 2024 · 0 comments
Open

Too many undefined values in API client #70

FelixTJDietrich opened this issue Sep 2, 2024 · 0 comments

Comments

@FelixTJDietrich
Copy link
Collaborator

FelixTJDietrich commented Sep 2, 2024

Current

A lot or all fields are marked with ? stating that they could be undefined even though the aren't:

export interface PullRequestDTO { 
    id?: number;
    title?: string;
    url?: string;
    state?: PullRequestDTO.StateEnum;
    createdAt?: string;
    updatedAt?: string;
    mergedAt?: string;
    author?: UserDTO;
    comments?: Set<IssueCommentDTO>;
    repository?: RepositoryDTO;
}
export namespace PullRequestDTO {
    export type StateEnum = 'CLOSED' | 'OPEN';
    export const StateEnum = {
        Closed: 'CLOSED' as StateEnum,
        Open: 'OPEN' as StateEnum
    };
}

Expected

Most of the fields are actually defined and therefore should not be optional in the OpenAPI specs

@FelixTJDietrich FelixTJDietrich added bug Something isn't working application-server client and removed bug Something isn't working labels Sep 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant