We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3b1c10c commit 5ce087aCopy full SHA for 5ce087a
@stellar/typescript-wallet-sdk/src/walletSdk/Uri/sep7Parser.ts
@@ -167,8 +167,14 @@ export const sep7ReplacementsFromString = (
167
const txrepList = txrepString.split(LIST_DELIMITER);
168
const txrepIds: string[] = [];
169
txrepList.forEach((item) => {
170
- const id = item.split(ID_DELIMITER)[1];
171
- if (id && txrepIds.indexOf(id) === -1) {
+ const parts = item.split(ID_DELIMITER);
+ if (parts.length < 2 || !parts[1]) {
172
+ throw new Sep7InvalidUriError(
173
+ "the 'replace' parameter has an entry missing a reference identifier",
174
+ );
175
+ }
176
+ const id = parts[1];
177
+ if (txrepIds.indexOf(id) === -1) {
178
txrepIds.push(id);
179
}
180
});
0 commit comments