Fixed secrets.json related bugs.