Skip to content

fix: use .text to handle empty project titles in user.loves() (#581)#588

Open
SyedAhris wants to merge 2 commits intoTimMcCool:mainfrom
SyedAhris:fix/loves-indexerror-empty-title
Open

fix: use .text to handle empty project titles in user.loves() (#581)#588
SyedAhris wants to merge 2 commits intoTimMcCool:mainfrom
SyedAhris:fix/loves-indexerror-empty-title

Conversation

@SyedAhris
Copy link
Copy Markdown

Fixes #581

The issue happens because .contents[0] throws an IndexError when a project has no title. Switching to .text returns an empty string instead, which handles that case cleanly.

@faretek1
Copy link
Copy Markdown
Collaborator

Hello. how are you?

@SyedAhris
Copy link
Copy Markdown
Author

Hi, Im great what about you?

@faretek1
Copy link
Copy Markdown
Collaborator

I was just thinking about my oven. I really need to use it tbh.

@SyedAhris
Copy link
Copy Markdown
Author

Okayy? Sure? Idk what you mean? Its my first time trying open source contribution.

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.

[Bug]: user.loves breaks on projects with empty title

2 participants