Skip to content

Commit

Permalink
Fix for #162, compatible with EE3 and EE4
Browse files Browse the repository at this point in the history
  • Loading branch information
croxton committed Aug 10, 2018
1 parent b35596e commit b89a6cd
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion system/user/addons/stash/mod.stash.php
Original file line number Diff line number Diff line change
Expand Up @@ -725,7 +725,15 @@ public function set($params=array(), $value='', $type='variable', $scope='user')
// this permits dynamic tag pairs, e.g. {stash:{key}}{/stash:{key}}
if ($this->parse_complete)
{
$tag_vars = ee()->functions->assign_variables(ee()->TMPL->tagdata);
if (version_compare(APP_VER, '4.0', '>='))
{
$tag_vars = ee('Variables/Parser')->extractVariables(ee()->TMPL->tagdata);
}
else
{
$tag_vars = ee()->functions->assign_variables(ee()->TMPL->tagdata);
}

$tag_pairs = $tag_vars['var_pair'];
}
else
Expand Down

0 comments on commit b89a6cd

Please sign in to comment.