From 494882adadb33ffb7a7a9b2fa9356362df87d3bf Mon Sep 17 00:00:00 2001 From: Joerg Bornemann <joerg.bornemann@digia.com> Date: Tue, 14 Jan 2014 11:11:00 +0100 Subject: [PATCH] fix conditionals in DayTimeDuration::stringValue() Task-number: QTBUG-35479 Change-Id: If385bd85f5c20871a0248c828626deea2d72e0a2 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Peter Hartmann <phartmann@blackberry.com> --- src/xmlpatterns/data/qdaytimeduration.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/xmlpatterns/data/qdaytimeduration.cpp b/src/xmlpatterns/data/qdaytimeduration.cpp index c21e3529..5f273d7a 100644 --- a/src/xmlpatterns/data/qdaytimeduration.cpp +++ b/src/xmlpatterns/data/qdaytimeduration.cpp @@ -145,8 +145,7 @@ QString DayTimeDuration::stringValue() const retval.append(QLatin1Char('D')); } - if(!m_hours && !m_minutes && !m_seconds && !m_seconds) - { + if (!m_hours && !m_minutes && !m_seconds && !m_mseconds) { if(!m_days) return QLatin1String("PT0S"); else @@ -167,8 +166,7 @@ QString DayTimeDuration::stringValue() const retval.append(QLatin1Char('M')); } - if(m_seconds || m_seconds) - { + if (m_seconds || m_mseconds) { retval.append(QString::number(m_seconds)); if(m_mseconds) -- GitLab