[Pkg-mozext-commits] [sage-extension] 07/49: bug 8058

David Prévot taffit at moszumanska.debian.org
Fri May 1 03:10:52 UTC 2015


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to tag sage_1_3_10
in repository sage-extension.

commit 6cc4ffd7c917af851f3ed77bb23174689da9fa96
Author: Peter Andrews <petea at jhu.edu>
Date:   Mon May 9 01:42:46 2005 +0000

    bug 8058
---
 src/sage/content/updatechecker.js | 24 +++++++++++++++---------
 1 file changed, 15 insertions(+), 9 deletions(-)

diff --git a/src/sage/content/updatechecker.js b/src/sage/content/updatechecker.js
index 0a881ac..c4d2c59 100755
--- a/src/sage/content/updatechecker.js
+++ b/src/sage/content/updatechecker.js
@@ -3,7 +3,19 @@ var UpdateChecker = {
 	checkList: null,
 	httpReq: null,
 	lastResource: null,
-
+	
+	getURL: function(resource) {
+		var type = CommonFunc.getBMDSProperty(resource, CommonFunc.RDF_TYPE);
+		var url;
+		if(type == NC_NS + "Bookmark") {
+			url = CommonFunc.getBMDSProperty(resource, CommonFunc.BM_URL);
+		}
+		if(type == NC_NS + "Livemark") {
+			url = CommonFunc.getBMDSProperty(resource, CommonFunc.BM_FEEDURL);
+		}
+		return url;
+	},
+	
 	startCheck: function(aCheckFolderId) {
 		if(this.checking) return;
 
@@ -12,7 +24,7 @@ var UpdateChecker = {
 
 		// select feeds to be checked, exclude separators and updated feeds
 		for(var i = 0; i < resourceList.length; i++) {
-			var url = CommonFunc.getBMDSProperty(resourceList[i], CommonFunc.BM_URL);
+			var url = this.getURL(resourceList[i]);
 			var desc = CommonFunc.getBMDSProperty(resourceList[i], CommonFunc.BM_DESCRIPTION);
 			var status = desc.split(" ")[0];
 			if(url && !(status == CommonFunc.STATUS_UPDATE || status == CommonFunc.STATUS_NO_CHECK)) {
@@ -38,13 +50,7 @@ var UpdateChecker = {
 		this.lastResource = this.checkList.shift();
 		var name = CommonFunc.getBMDSProperty(this.lastResource, CommonFunc.BM_NAME);
 		var type = CommonFunc.getBMDSProperty(this.lastResource, CommonFunc.RDF_TYPE);
-		var url;
-		if(type == NC_NS + "Bookmark") {
-			url = CommonFunc.getBMDSProperty(this.lastResource, CommonFunc.BM_URL);
-		}
-		if(type == NC_NS + "Livemark") {
-			url = CommonFunc.getBMDSProperty(this.lastResource, CommonFunc.BM_FEEDURL);
-		}
+		var url = this.getURL(this.lastResource);
 
 		if(!url) {
 			this.checkResult(false, 0);

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/sage-extension.git



More information about the Pkg-mozext-commits mailing list