Closed kkda closed 10 years ago
This is the same for querylist helper
Generally Erfurt seams to rewrite "0" to empty strings when you da a sparqlQuery. So this should be an Erfurt issue.
Output of literal helper works fine with this change:
diff --git a/helpers/DisplayLiteralPropertyValue.php b/helpers/DisplayLiteralPropertyValue.php
index 8aa7129..1728a5f 100644
--- a/helpers/DisplayLiteralPropertyValue.php
+++ b/helpers/DisplayLiteralPropertyValue.php
@@ -19,7 +19,7 @@ class Site_View_Helper_DisplayLiteralPropertyValue extends Zend_View_Helper_Abst
{
public function displayLiteralPropertyValue($value = null, $property = '', $datatype = 'http://www.w3.org/2001/XMLSchema#string')
{
- if (!$value) {
+ if ($value === null) {
$newValue = '';
} else {
$event = new Erfurt_Event('onDisplayLiteralPropertyValue');
So please commit this change and close this issue. Maybe the sparql query bug and this one has a different cause.
Committed in 221cf733d421b2d4883b6a1782759e21cd49909c.
Maybe check for null or for datatype there.