Skip to content

Commit

Permalink
Fix geosolutions-it#10530 fix catalog editor for array scenario
Browse files Browse the repository at this point in the history
  • Loading branch information
MV88 committed Sep 6, 2024
1 parent d9f5390 commit 0ee770e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions web/client/components/catalog/editor/MainForm.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* LICENSE file in the root directory of this source tree.
*/
import React, { useState, useEffect } from 'react';
import {get, find, isEmpty} from 'lodash';
import {isArray, get, find, isEmpty} from 'lodash';
import Message from '../../I18N/Message';
import HTML from '../../I18N/HTML';

Expand Down Expand Up @@ -157,7 +157,7 @@ export default ({
function handleProtocolValidity(url) {
onChangeUrl(url);
if (url) {
const isInvalidProtocol = !isValidURL(url, null, service?.allowUnsecureLayers);
const isInvalidProtocol = !isValidURL(isArray(url) ? url[0] : url, null, service?.allowUnsecureLayers);
setInvalidProtocol(isInvalidProtocol);
setValid(!isInvalidProtocol);
}
Expand Down

0 comments on commit 0ee770e

Please sign in to comment.