Attempt at fixing #342
Merge pull request #1181 from winterchord/h001046

Attempt at fixing #342