Skip to content

Commit

Permalink
修复通过场景联动发送阿里云短信失败问题 (#279)
Browse files Browse the repository at this point in the history
  • Loading branch information
bestfeng1020 authored May 4, 2023
1 parent fc5f9a5 commit 309e5a5
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package org.jetlinks.community.notify.sms.aliyun;

import com.alibaba.fastjson.JSON;
import com.google.common.collect.Maps;
import lombok.Getter;
import lombok.Setter;
import org.jetlinks.core.metadata.types.StringType;
Expand Down Expand Up @@ -64,7 +65,10 @@ public String getSignName(Map<String, Object> ctx) {
}

public String createTtsParam(Map<String, Object> ctx) {
return JSON.toJSONString(ctx);
Map<String, VariableDefinition> variables = getVariables();
return JSON.toJSONString(Maps.filterEntries(
renderMap(ctx),
e -> variables.containsKey(e.getKey())));
}

@Override
Expand Down

0 comments on commit 309e5a5

Please sign in to comment.