That applies specifically to astrophotography where the subject isn’t filling the frame. If you increase the focal length, the subject fills the frame more, so more light is gathered from that subject.
It also applies to wildlife photography where you need to crop, for the same reasons.
It doesn’t apply to general purpose photography, though, because we do things on a per-full-image basis, not a per-degree basis. As you increase focal length, you gather more light per degree of subject but you have less subject in the frame.