Skip to content

Commit

Permalink
fix(all): Fix in AS IMAGE generation of single row.
Browse files Browse the repository at this point in the history
  • Loading branch information
rodrigorodriguez committed Jul 23, 2023
1 parent 312db22 commit 576e73b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
9 changes: 5 additions & 4 deletions packages/basic.gblib/services/DialogKeywords.ts
Original file line number Diff line number Diff line change
Expand Up @@ -603,13 +603,14 @@ export class DialogKeywords {
}

/**
* Returns a custom user param persisted on storage.
* Returns bot param persisted on storage.
*
* @example GET PARAM name
* @example GET CONFIG name
*
*/
public async getUserParam({ pid, name }) {
await DialogKeywords.getOption({ pid, name });
public async getConfig({ pid, name }) {
let { min, user, params } = await DialogKeywords.getProcessInfo(pid);
return min.core.getParam(min.instance, name, null);
}

/**
Expand Down
4 changes: 2 additions & 2 deletions packages/basic.gblib/services/KeywordsExpressions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -304,9 +304,9 @@ export class KeywordsExpressions {
];

keywords[i++] = [
/^\s*((?:[a-z]+.?)(?:(?:\w+).)(?:\w+)*)\s*=\s*get param\s*(.*)/gim,
/^\s*((?:[a-z]+.?)(?:(?:\w+).)(?:\w+)*)\s*=\s*get config\s*(.*)/gim,
($0, $1, $2) => {
return `${$1} = await dk.getUserParam ({pid: pid, ${$2}})`;
return `${$1} = await dk.getConfig ({pid: pid, ${$2}})`;
}
];

Expand Down

0 comments on commit 576e73b

Please sign in to comment.