From 62e25f6c13320837bdf792a8f01a67ba5e58061f Mon Sep 17 00:00:00 2001 From: Ludovic Marcotte Date: Thu, 27 Feb 2020 15:26:39 -0500 Subject: [PATCH] fix(calendar(core)): avoid generating empty parameters list --- SOPE/NGCards/CardVersitRenderer.m | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/SOPE/NGCards/CardVersitRenderer.m b/SOPE/NGCards/CardVersitRenderer.m index 997935e28..35ffc96f8 100644 --- a/SOPE/NGCards/CardVersitRenderer.m +++ b/SOPE/NGCards/CardVersitRenderer.m @@ -1,8 +1,6 @@ /* CardVersitRenderer.m - this file is part of SOPE * - * Copyright (C) 2006-2012 Inverse inc. - * - * Author: Wolfgang Sourdeau + * Copyright (C) 2006-2020 Inverse inc. * * This file is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -49,7 +47,7 @@ - (NSString *) renderElement: (CardElement *) anElement { - NSMutableString *rendering; + NSMutableString *rendering, *buffer; NSDictionary *attributes; NSMutableDictionary *values; NSString *finalRendering, *tag; @@ -73,10 +71,12 @@ attributes = [anElement attributes]; if ([attributes count]) { - [rendering appendString: @";"]; - [attributes versitRenderInString: rendering + buffer = [NSMutableString string]; + [attributes versitRenderInString: buffer withKeyOrdering: [anElement orderOfAttributeKeys] asAttributes: YES]; + if ([buffer length]) + [rendering appendFormat: @";%@", buffer]; } /* values */