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

Only import ImageFont in ImageDraw when necessary #6341

Merged
merged 1 commit into from
Jun 5, 2022

Conversation

radarhere
Copy link
Member

#5510 added an ImageFont to the top of ImageDraw, not noticing that ImageDraw already imports ImageFont later on.

from . import ImageFont
self.font = ImageFont.load_default()

This PR changes the import from #5510 to only run when necessary, following the original pattern.

@hugovk hugovk merged commit 418820a into python-pillow:main Jun 5, 2022
@radarhere radarhere deleted the imagedraw branch June 5, 2022 22:39
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.

2 participants