Make plugin compatible with both runtimes (old and new)