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

Fixed project not opening with missing background #850

Merged
merged 1 commit into from Apr 4, 2021

Conversation

rbb8403
Copy link
Contributor

@rbb8403 rbb8403 commented Apr 4, 2021

This should fix Issue #786 where Manuskript project files wouldn't open if the custom corkboard image was missing. The problem is that findFirstFile returns None if it doesn't find a file, so I added a check to see if the image was None to prevent it from trying to open a resource which doesn't exist. This is the quick way to patch this. I'd recommend changing the findFirstFile function in functions/init.py for a more permanent solution, but I don't know the knock-on effects of that, so this should suffice for now. Another suggestion could be to bundle custom image resources in the project file. Or, throw in some error handling.

This is the quick way to patch this. I'd recommend changing the findFirstFile function in functions/__init__.py for a more permanent solution, but this should suffice for now.
@TheJackiMonster
Copy link
Collaborator

Looks fine to me for now. ^^

@TheJackiMonster TheJackiMonster merged commit 8faca87 into olivierkes:develop Apr 4, 2021
@TheJackiMonster TheJackiMonster added this to the 0.12.0 milestone Apr 4, 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 this pull request may close these issues.

None yet

2 participants