Index: trunk/extensions/SemanticInternalObjects/SemanticInternalObjects_body.php |
— | — | @@ -150,8 +150,8 @@ |
151 | 151 | 'value_num' => $valueNum |
152 | 152 | ); |
153 | 153 | |
154 | | - // getUnit() was removed in SMW 1.6 |
155 | | - if ( method_exists( $value, 'getUnit' ) ) { |
| 154 | + // 'value_unit' DB field was removed in SMW 1.6 |
| 155 | + if ( version_compare( SMW_VERSION, '1.6 alpha', '<' ) ) { |
156 | 156 | $upAttr['value_unit'] = $value->getUnit(); |
157 | 157 | } |
158 | 158 | |