Fix scope bug where peers was not defined