From eb54f3795fb276046c1a4c0e81fb5426f0659550 Mon Sep 17 00:00:00 2001 From: Christian Mollekopf Date: Thu, 17 May 2018 16:55:37 +0200 Subject: Fixed last commit --- common/domain/applicationdomaintype.cpp | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/common/domain/applicationdomaintype.cpp b/common/domain/applicationdomaintype.cpp index 3aadc2c..b0be729 100644 --- a/common/domain/applicationdomaintype.cpp +++ b/common/domain/applicationdomaintype.cpp @@ -49,8 +49,16 @@ QDebug Sink::ApplicationDomain::operator<< (QDebug d, const Sink::ApplicationDom } d << " " << "Resource: " << "\t" << type.resourceInstanceIdentifier() << "\n"; for (const auto &property : properties) { - //We limit the maximum length of the property for large blob properties. - d << " " << property << "\t" << type.getProperty(property).mid(0, 75) << "\n"; + const auto value = type.getProperty(property); + if (value.canConvert()) { + //We limit the maximum length of the property for large blob properties. + d << " " << property << "\t" << value.toString().mid(0, 75) << "\n"; + } else if (value.canConvert()) { + //We limit the maximum length of the property for large blob properties. + d << " " << property << "\t" << value.toByteArray().mid(0, 75) << "\n"; + } else { + d << " " << property << "\t" << value << "\n"; + } } d << ")"; return d; -- cgit v1.2.3