Commit 66469988 authored by Leigh Stoller's avatar Leigh Stoller

Repo based profile fix for bug David noticed; do not update the master

when the repo changes, unless its the manage profile page and its the
profile creator (the same code is shared in different places).
parent 36a048ec
......@@ -1394,6 +1394,7 @@ $(function ()
var args = {
"script" : script,
"pid" : $('#profile_pid').val(),
"editokay" : true,
};
if (repoupdate_callback !== undefined) {
// Pass along uuid as a flag to update repo.
......
......@@ -812,7 +812,14 @@ function Do_CheckScript()
$blob["paramdefs"] = $paramdefs;
}
}
#
# We use this routine from the manage/instantiate/show pages,
# but we do not want to update the master unless it the profile
# creator and it is the manage profile page.
#
if (!isset($profile) ||
!isset($ajax_args["editokay"]) ||
$this_idx != $profile->creator_idx() ||
UpdateMaster($profile, $ajax_args["script"], $blob["rspec"]) == 0) {
SPITAJAX_RESPONSE($blob);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment