Skip to content

Commit bc32397

Browse files
chenzrgdxjy
andauthored
Feat new pushcustom (#189)
* custom push * filter not local domain push * filter not local domain push Co-authored-by: gdxjy <[email protected]>
1 parent 80941b4 commit bc32397

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

pushsender/rpc/grpc_server.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,9 @@ func (s *Server) SetPushFailTimes(pusher pushapitypes.PusherWitchInterfaceData,
189189

190190
func (s *Server) doCustomPush(data *pushapitypes.PushPubContents,
191191
pushContent *pushapitypes.PushPubContent) {
192+
if !common.CheckValidDomain(common.GetDomainByUserID(pushContent.UserID), s.cfg.Matrix.ServerName) {
193+
return
194+
}
192195
notify := s.createNotify(data, pushContent, nil, nil)
193196
if notify == nil {
194197
return

0 commit comments

Comments
 (0)