fixes for outdated jconstruct, thanks for Melkorbsd