Updated code to make it compatible with Elcodi~0.3