Permalink
Browse files

Fixed version checker bug in bertatemplate class.

  • Loading branch information...
1 parent d4f2322 commit 9c0be7ef6681ff35acf1ee1278291760221fbd83 @kasparszarinovs kasparszarinovs committed Mar 28, 2012
Showing with 1 addition and 4 deletions.
  1. +1 −1 engine/_classes/class.bertatemplate.php
  2. +0 −3 templates/messy-0.4.0/mess.js
@@ -306,7 +306,7 @@ private function addEngineVariables() {
// gets berta's version at the time the section was last updated
$blog = BertaContent::loadBlog($this->sectionName);
- if(array_key_exists('@attributes',$blog)) $lastUpdVer = $blog['@attributes']['last_upd_ver'];
+ if(!empty($blog['@attributes']['last_upd_ver'])) $lastUpdVer = $blog['@attributes']['last_upd_ver'];
else $lastUpdVer = 0;
// berta scripts ...
@@ -24,10 +24,8 @@ var MessyMess = new Class({
window.addEvent('load', this.onLoad.bind(this));
/* Backup for versions pre 0.8.2, if not updated */
- console.log(parseInt(bertaGlobalOptions['lastUpdVer']));
if(parseInt(bertaGlobalOptions['lastUpdVer']) < 1082) {
BertaGallery.implement({
-
layout_update: function() {
if(this.type == 'pile' || this.type == 'row') {
var margin = 0;
@@ -61,7 +59,6 @@ var MessyMess = new Class({
this.imageContainer.setStyle('width', maxWidth + 'px');
}
}
-
});
}
},

0 comments on commit 9c0be7e

Please sign in to comment.