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

refactor: refactor AddPageToDatabase function to use Person struc… #20

Merged
merged 1 commit into from
Jan 25, 2024

Conversation

kkdai
Copy link
Owner

@kkdai kkdai commented Jan 25, 2024

…t instead of individual field parameters

  • Modify the AddPageToDatabase function to accept a Person struct parameter
  • Remove the individual field parameters in the AddPageToDatabase function and use the Person struct instead
  • Update the properties passed to the AddPageToDatabase function with the corresponding fields from the Person struct
  • Add the Company field to the Person struct
  • Retrieve the Company value from the page in the createEntryFromPage function
  • Remove the logging of individual field values and log the Person struct instead
  • Update the test case in TestAddNotionDB to pass a Person struct as a parameter to AddPageToDatabase
  • Add an empty line in TestAddNotionDB

…t instead of individual field parameters

- Modify the `AddPageToDatabase` function to accept a `Person` struct parameter
- Remove the individual field parameters in the `AddPageToDatabase` function and use the `Person` struct instead
- Update the properties passed to the `AddPageToDatabase` function with the corresponding fields from the `Person` struct
- Add the `Company` field to the `Person` struct
- Retrieve the `Company` value from the page in the `createEntryFromPage` function
- Remove the logging of individual field values and log the `Person` struct instead
- Update the test case in `TestAddNotionDB` to pass a `Person` struct as a parameter to `AddPageToDatabase`
- Add an empty line in `TestAddNotionDB`

Signed-off-by: Evan Lin <[email protected]>
@kkdai kkdai merged commit 66ea46b into main Jan 25, 2024
1 check passed
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 this pull request may close these issues.

1 participant