From caca929db6dacc79c2e2ff38e3c52b2a887a7a34 Mon Sep 17 00:00:00 2001 From: Kolin Krewinkel Date: Wed, 28 Oct 2015 16:36:21 -0700 Subject: [PATCH] Coalesce the two conditions --- .../Categories/DVTTextStorage+PLYHighlightingHook.m | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/Polychromatic/Categories/DVTTextStorage+PLYHighlightingHook.m b/Polychromatic/Categories/DVTTextStorage+PLYHighlightingHook.m index 8565951..d079179 100644 --- a/Polychromatic/Categories/DVTTextStorage+PLYHighlightingHook.m +++ b/Polychromatic/Categories/DVTTextStorage+PLYHighlightingHook.m @@ -100,11 +100,7 @@ - (NSColor *)ply_colorForSwiftCodeRange:(NSRange)range context:(id)context fallb - (NSColor *)ply_colorForObjCCodeRange:(NSRange)range context:(id)context fallbackColor:(NSColor *)fallbackColor { DVTSourceModelItem *item = [self.sourceModelService sourceModelItemAtCharacterIndex:range.location]; - if (item.needsAdjustNodeType) { - return fallbackColor; - } - - if (![item ply_isIdentifier]) { + if (item.needsAdjustNodeType || ![item ply_isIdentifier]) { return fallbackColor; }