In your particular use case, you try to destroy the viewer during its creation and we do not tested this scenario.
I made some modification to make this possible.
Can you tell me in which case you want to destroy the viewer the very next line after its creation? I'm just curious
Maybe you just make test?
My fixes are in a github branch called rroux-destroy here: https://github.com/gopro/forgejs/tree/rroux-destroy
It will be merged in the master as soon as the code is reviewed.
Have a nice day!