[Pkg-mozext-commits] [wot] 198/226: Fixes and using production servers again.
David Prévot
taffit at moszumanska.debian.org
Fri May 1 00:35:51 UTC 2015
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository wot.
commit 6717a79c7123cc065f70f52c11291598c172da7c
Author: Sergey Andryukhin <sorgoz at yandex.com>
Date: Tue Mar 11 16:52:25 2014 +0200
Fixes and using production servers again.
---
content/api.js | 3 +--
content/rw/wot.js | 58 +++++++++++++++++++++++++++++++-----------------------
content/surveys.js | 2 +-
3 files changed, 35 insertions(+), 28 deletions(-)
diff --git a/content/api.js b/content/api.js
index 398d3b8..ec65d51 100644
--- a/content/api.js
+++ b/content/api.js
@@ -1227,8 +1227,7 @@ wot_modules.push({ name: "wot_keeper", obj: wot_keeper });
var wot_website_api = {
-// server: "www.mywot.com",
- server: "dev.mywot.com",
+ server: "www.mywot.com",
version: "1", // Comments API version
nonces: {}, // to know connection between nonce and target
diff --git a/content/rw/wot.js b/content/rw/wot.js
index 0700338..fa84112 100644
--- a/content/rw/wot.js
+++ b/content/rw/wot.js
@@ -19,7 +19,7 @@
*/
var wot = {
- version: 20140217,
+ version: 20140311,
platform: "firefox",
locale: "en", // cached value of the locale
lang: "en-US", // cached value of the lang
@@ -32,6 +32,7 @@ var wot = {
// environment (browser, etc)
env: {
is_mailru: false,
+ is_mailru_amigo: false,
is_yandex: false,
is_rambler: false,
@@ -115,20 +116,20 @@ var wot = {
},
urls: {
- base: "http://www.mywot.com/",
- scorecard: "http://www.mywot.com/scorecard/",
- settings: "http://www.mywot.com/settings",
- profile: "http://www.mywot.com/user",
+ base: "https://www.mywot.com/",
+ scorecard: "https://www.mywot.com/scorecard/",
+ settings: "https://www.mywot.com/settings",
+ profile: "https://www.mywot.com/user",
signup: "https://www.mywot.com/signup",
- welcome: "http://www.mywot.com/settings/welcome",
- setcookies: "http://www.mywot.com/setcookies.php",
- update: "http://www.mywot.com/update",
- tour_warning:"http://www.mywot.com/support/tour/warningscreen",
- tour: "http://www.mywot.com/support/tour/",
- tour_rw: "http://www.mywot.com/support/tour/ratingwindow",
- tour_scorecard: "http://www.mywot.com/support/tour/scorecard",
- wg: "https://dev.mywot.com/en/groups/g",
- wg_about: "https://dev.mywot.com/en/groups",
+ welcome: "https://www.mywot.com/settings/welcome",
+ setcookies: "http://www.mywot.com/setcookies.php", // this can be only http because the add-on doesn't have permission to access https
+ update: "https://www.mywot.com/update",
+ tour_warning:"https://www.mywot.com/support/tour/warningscreen",
+ tour: "https://www.mywot.com/support/tour/",
+ tour_rw: "https://www.mywot.com/support/tour/ratingwindow",
+ tour_scorecard: "https://www.mywot.com/support/tour/scorecard",
+ wg: "https://beta.mywot.com/en/groups/g",
+ wg_about: "https://beta.mywot.com/en/groups",
contexts: {
rwlogo: "rw-logo",
@@ -142,18 +143,23 @@ var wot = {
rwcaptcha: "rw-captcha",
warnviewsc: "warn-viewsc",
warnrate: "warn-rate",
- popupviewsc: "popup",
- popuprate: "popup-rate",
- popupdonuts: "popup-donuts",
+ popupviewsc: "popup",
+ popuprate: "popup-rate",
+ popupdonuts: "popup-donuts",
fbl_logo: "fbl-logo",
wt_intro: "wt-intro",
wt_rw_lm: "wt-rw-lm",
wt_warn_lm: "wt-warn-lm",
- wt_warn_logo: "wt-warn-logo",
- wt_donuts_lm: "wt-donuts-lm",
- wt_donuts_logo: "wt-donuts-logo",
- wg_tag: "wg-tag",
+ wt_warn_logo: "wt-warn-logo",
+ wt_donuts_lm: "wt-donuts-lm",
+ wt_donuts_logo: "wt-donuts-logo",
+ wg_tag: "wg-tag",
wg_about_learnmore: "wg-learnmore"
+ },
+
+ geturl: function (url) {
+ var is_wg = wot.ratingwindow ? wot.ratingwindow.is_wg_allowed : (wot.core ? wot.core.tags.is_wg_allowed : false);
+ return is_wg ? url.replace('www.mywot.com', 'beta.mywot.com') : url;
}
},
@@ -632,6 +638,7 @@ var wot = {
// try to understand in which environment we are run
var user_agent = window.navigator.userAgent || "";
wot.env.is_mailru = user_agent.indexOf("MRCHROME") >= 0;
+ wot.env.is_mailru_amigo = user_agent.indexOf("MRCHROME SOC") >= 0;
// old yandex browser is named "Yandex Internet" (chromium 18), new browser is named "YaBrowser" (chromium 22+)
wot.env.is_yandex = user_agent.indexOf("YaBrowser") >= 0 || user_agent.indexOf(" YI") >= 0;
@@ -643,10 +650,11 @@ var wot = {
wot.partner = "yandex";
}
- if(!readonly) wot.prefs.set("partner", wot.partner);
-
- // Is the mode "accessible" set on?
- wot.env.is_accessible = wot.prefs.get("accessible");
+ if (wot.prefs) {
+ if(!readonly) wot.prefs.set("partner", wot.partner);
+ // Is the mode "accessible" set on?
+ wot.env.is_accessible = wot.prefs.get("accessible");
+ }
},
cache_locale: function () {
diff --git a/content/surveys.js b/content/surveys.js
index 1394fec..5eb58c7 100644
--- a/content/surveys.js
+++ b/content/surveys.js
@@ -85,7 +85,7 @@ var wot_surveys = {
var content = event.originalTarget,
location = (content && content.location) ? content.location : {};
- var is_framed = (content.defaultView != content.defaultView.top);
+ var is_framed = (content.defaultView && content.defaultView != content.defaultView.top);
// Process framed documents differently than normal ones
if (is_framed) {
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/wot.git
More information about the Pkg-mozext-commits
mailing list