From 19ce9f87b2a8e423de6d8ffb81717a5cdd620193 Mon Sep 17 00:00:00 2001 From: Offray Luna Date: Fri, 11 Feb 2022 15:56:21 -0500 Subject: [PATCH] Improving metadata cleaning. --- repository/Grafoscopio-Utils/LePage.extension.st | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/repository/Grafoscopio-Utils/LePage.extension.st b/repository/Grafoscopio-Utils/LePage.extension.st index 66f7f32..a4d60d4 100644 --- a/repository/Grafoscopio-Utils/LePage.extension.st +++ b/repository/Grafoscopio-Utils/LePage.extension.st @@ -121,5 +121,7 @@ LePage >> preorderTraversal [ { #category : #'*Grafoscopio-Utils-Core' } LePage >> removeSnippetsMetadata [ - self preorderTraversal do: [ :snippet | snippet options removeKey: 'metadata' ] + self preorderTraversal do: [ :snippet | + (snippet options isNotNil and: [ snippet options includesKey: 'metadata' ]) + ifTrue: [ snippet options removeKey: 'metadata' ] ] ]