At the end of the Brooklyn Nine Nine episode "Game Night", Jake and the rest of the guys show up at Rosa's apartment. How does everyone know where Rosa lives? Isn't that supposed to be a secret?
I assume that the guys already knew how to get there because, in the last episode of season 3 ("Greg and Larry"), Rosa let them use her house as a safe house.
Watching that episode and the episode you mentioned, it seems that it is the same apartment.
In season 3, Jake and his friends were in mortal danger and needed to seek refuge from the enemies. Jake called up Rosa to ask for help, and she offered him the apartment as a safe house.
This is not shown, but Jake talks about this to Charles. Therefore, in the episode where everyone sees Rosa's apartment, Jake isn't that shocked, which indicates that he already knew where she lived.