Skip to content

[BUG] Incorrect schedule variable value if it contains variable regex separator in "value" part #32

@romanchetto

Description

@romanchetto

If try to add the next schedule variable: URL:https://example.com the plugin creates URL : https key value pair, ignoring //example.com part of value.
image

This occurs due to this part of code:

String[] splittedKeyAndValue = rawKeyValuePair.split(variableSeparatorRegex);
if(splittedKeyAndValue.length < 2){
listener.getLogger().println(String.format(Messages.INVALID_SCHEDULE_VARIABLE,rawKeyValuePair));
continue;
}
String key = splittedKeyAndValue[0];
String value = splittedKeyAndValue[1];

Array splittedKeyAndValue contains 3 elements in this case, were 3rd one contains missed //example.com

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions