File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed
governance/xc_admin/packages/xc_admin_frontend/components/tabs Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -245,10 +245,21 @@ const General = () => {
245
245
}
246
246
} )
247
247
248
+ // check that there are no duplicate publishers
249
+ Object . keys ( jsonParsed ) . forEach ( ( symbol ) => {
250
+ if (
251
+ new Set ( jsonParsed [ symbol ] . priceAccounts [ 0 ] . publishers ) . size !=
252
+ jsonParsed [ symbol ] . priceAccounts [ 0 ] . publishers . length
253
+ ) {
254
+ toast . error ( `${ symbol } has a duplicate publisher.` )
255
+ isValid = false
256
+ }
257
+ } )
258
+
248
259
// check that no price account has more than 32 publishers
249
260
Object . keys ( jsonParsed ) . forEach ( ( symbol ) => {
250
261
if ( jsonParsed [ symbol ] . priceAccounts [ 0 ] . publishers . length > 32 ) {
251
- toast . error ( `A price account can't have more than 32 publishers.` )
262
+ toast . error ( `${ symbol } has more than 32 publishers.` )
252
263
isValid = false
253
264
}
254
265
} )
You can’t perform that action at this time.
0 commit comments