Refactor for indentation

Fix specs as well