CC-2950: Tell users if they are running an out-of-date version or not
1. changed the behavior so that the tooltip comes up on hover 2. changed stat server link to "http://stat.sourcefabric.org/airtime_latest_version" 3. only updates the db if version returned by stat server is valid
This commit is contained in:
parent
becaf7a152
commit
51c563f80b
3 changed files with 3 additions and 5 deletions
|
@ -528,11 +528,10 @@ class Application_Model_Preference
|
|||
|
||||
public static function SetLatestVersion($version){
|
||||
$pattern = "/^[0-9]+\.[0-9]+\.[0-9]+/";
|
||||
if(!preg_match($pattern, $version)) {
|
||||
$version = self::GetAirtimeVersion();
|
||||
}
|
||||
if(preg_match($pattern, $version)) {
|
||||
self::SetValue("latest_version", $version);
|
||||
}
|
||||
}
|
||||
|
||||
public static function SetUploadToSoundcloudOption($upload) {
|
||||
self::SetValue("soundcloud_upload_option", $upload);
|
||||
|
|
|
@ -29,7 +29,6 @@ function setupVersionQtip(){
|
|||
button: true
|
||||
}
|
||||
},
|
||||
show: 'click', /* Show on click */
|
||||
hide: false, /* Don't hide on mouseout */
|
||||
position: {
|
||||
my: "top right",
|
||||
|
|
|
@ -76,7 +76,7 @@ if(Application_Model_Preference::GetSupportFeedback() == '1'){
|
|||
|
||||
// Get latest version from stat server and store to db
|
||||
if(Application_Model_Preference::GetPlanLevel() == 'disabled'){
|
||||
$url = 'http://stat-dev.sourcefabric.org/airtime_latest_version';
|
||||
$url = 'http://stat.sourcefabric.org/airtime_latest_version';
|
||||
|
||||
$ch = curl_init();
|
||||
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue