modified lang() to work based of new options