Small refacturing of Engine