js: fix logging of frames