refactor routelang.js