Skip to content

Commit

Permalink
variables: Relax variable name validation
Browse files Browse the repository at this point in the history
Fixes #700
  • Loading branch information
tchx84 committed Jul 13, 2024
1 parent 92e675e commit c572e0c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/models/variables.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ const {GObject} = imports.gi;
const {FlatpakSharedModel} = imports.models.shared;
const {FlatsealOverrideStatus} = imports.models.overrideStatus;

var VAR_REGEXP = /^\w+=[\S ]+$/;
var VAR_REGEXP = /^[^;]+=[\S ]+$/;

var FlatpakVariablesModel = GObject.registerClass({
GTypeName: 'FlatpakVariablesModel',
Expand Down Expand Up @@ -75,7 +75,7 @@ var FlatpakVariablesModel = GObject.registerClass({

static deserialize(value) {
return value
.split(/(?=;[\w\s]+=)/)
.split(/(?=;[^;]+=)/)
.map(v => v.replace(/^;/, ''));
}

Expand Down

0 comments on commit c572e0c

Please sign in to comment.