Primary Office is always Sydney, Nova Scotia, where all the applications are submitted. Once the AOR is generated and sent to the applicants, the application is forwarded to the Secondary Office, which is Scarborough in your Case. Based on the theories from the forum, the secondary office is responsible for holding test and oath ceremonies. Earlier, the Secondary Office was determined on the basis of the location of the applicant (in other words the place where the applicant is residing) as would be easy for the applicant to visit the centre for the test or the venue for oath ceremony as both the test and oath were in person. Now keeping in mind the different backlog scenarios in different offices, the applications can be forwarded to any processing office which has a relatively handled backlog situation, irrespective of the location of the applicant, mainly because nowadays citizenship tests and oath ceremonies are held online rather than in person.
Someone shared in the forum, in July 2022 Citizenship Application Thread, that the Primary Office (Sydney, Nova Scotia) checks whether the application is complete or not. Even after forwarding the application to the Secondary Office, the Primary Office handles the elements of Prohibitions, Language, Physical Presence and Background Check.
Sharing the link of July 2022 Thread specifically discussing the role of primary and secondary office
https://www.canadavisa.com/canada-immigration-discussion-board/threads/july-2022-citizenship-applications.771789/page-5
Regards