BUG: fix previous commit

Acutally use the opening logic