Author: locilka Date: Wed Aug 31 12:19:41 2011 New Revision: 65464
URL: http://svn.opensuse.org/viewcvs/yast?rev=65464&view=rev Log: Simplifying the previous commit (bnc#714027)
Modified: branches/SuSE-Code-11-SP2-Branch/packager/package/yast2-packager.changes branches/SuSE-Code-11-SP2-Branch/packager/src/modules/AddOnProduct.ycp
Modified: branches/SuSE-Code-11-SP2-Branch/packager/package/yast2-packager.changes URL: http://svn.opensuse.org/viewcvs/yast/branches/SuSE-Code-11-SP2-Branch/packag... ============================================================================== --- branches/SuSE-Code-11-SP2-Branch/packager/package/yast2-packager.changes (original) +++ branches/SuSE-Code-11-SP2-Branch/packager/package/yast2-packager.changes Wed Aug 31 12:19:41 2011 @@ -1,4 +1,9 @@ ------------------------------------------------------------------- +Wed Aug 31 12:18:19 CEST 2011 - locilka@suse.cz + +- Simplifying the previous commit (bnc#714027) + +------------------------------------------------------------------- Mon Aug 29 16:15:53 CEST 2011 - locilka@suse.cz
- Implemented possibility to set repository priority while adding
Modified: branches/SuSE-Code-11-SP2-Branch/packager/src/modules/AddOnProduct.ycp URL: http://svn.opensuse.org/viewcvs/yast/branches/SuSE-Code-11-SP2-Branch/packag... ============================================================================== --- branches/SuSE-Code-11-SP2-Branch/packager/src/modules/AddOnProduct.ycp (original) +++ branches/SuSE-Code-11-SP2-Branch/packager/src/modules/AddOnProduct.ycp Wed Aug 31 12:19:41 2011 @@ -1292,28 +1292,9 @@ * @returns boolean if successful */ boolean RepositorySetPriority (integer repo_id, integer priority) { - list <map <string, any> > repos = Pkg::SourceEditGet(); - - map <string, any> edit_repo = $[]; - - integer counter = -1; - foreach (map <string, any> repo, repos, { - counter = counter + 1; - if (repo["SrcId"]:-1 == repo_id) { - edit_repo = repo; - break; - } - }); - - if (edit_repo == $[]) { - y2error ("Cannot find repository ID: %1", repo_id); - return false; - } - - edit_repo["priority"] = priority; - repos[counter] = edit_repo; - - return Pkg::SourceEditSet (repos); + map <string, any> edit_repo = $["SrcId" : repo_id, "priority" : priority]; + y2milestone ("Adjusting repo priority: %1", edit_repo); + return Pkg::SourceEditSet ([edit_repo]); }
/**
yast-commit@lists.opensuse.org