handle default as well as index