Skip to content

Commit

Permalink
correctifs actual
Browse files Browse the repository at this point in the history
  • Loading branch information
schpill committed Jun 14, 2017
1 parent 7046448 commit 919b234
Showing 1 changed file with 14 additions and 9 deletions.
23 changes: 14 additions & 9 deletions lib/lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -5034,21 +5034,26 @@ function event($name, callable $closure = null, array $args = [])
}
}

function actual($key = null, $value = 'octodummy')
function actual()
{
$actuals = Registry::get('core.actuals', []);
$args = func_get_args();
$num = func_num_args();
$key = array_shift($args);
$value = array_shift($args);

if (!is_null($key)) {
if ('octodummy' == $value) {
return isAke($actuals, $key, null);
}
$actuals = Registry::get('core.actuals', []);

$actuals[$key] = $value;
if (is_null($key)) {
return $actuals;
}

Registry::set('core.actuals', $actuals);
if (1 == $num) {
return isAke($actuals, $key, null);
}

return $actuals;
$actuals[$key] = $value;

Registry::set('core.actuals', $actuals);
}

function fire($event, array $args = [])
Expand Down

0 comments on commit 919b234

Please sign in to comment.