[ https://issues.apache.org/jira/browse/LUCENE-9303?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
kkewwei updated LUCENE-9303: ---------------------------- Description: In DefaultIndexingChain.processField() {code:java} if (fieldType.stored()) { if (fp == null) { fp = getOrAddField(fieldName, fieldType, false); } if (fieldType.stored()) { String value = field.stringValue(); ...... try { storedFieldsConsumer.writeField(fp.fieldInfo, field); } catch (Throwable th) { ...... } } } {code} If there has need to add the second {{if}}, because {{fieldType.stored()}} is executed before. was: {code:java} {code} In DefaultIndexingChain.processField() {code:java} // code placeholder {code} > There may be can simpler in DefaultIndexingChain > ------------------------------------------------ > > Key: LUCENE-9303 > URL: https://issues.apache.org/jira/browse/LUCENE-9303 > Project: Lucene - Core > Issue Type: Improvement > Components: core/index > Affects Versions: 8.2 > Reporter: kkewwei > Priority: Major > > In DefaultIndexingChain.processField() > {code:java} > if (fieldType.stored()) { > if (fp == null) { > fp = getOrAddField(fieldName, fieldType, false); > } > if (fieldType.stored()) { > String value = field.stringValue(); > ...... > try { > storedFieldsConsumer.writeField(fp.fieldInfo, field); > } catch (Throwable th) { > ...... > } > } > } > {code} > If there has need to add the second {{if}}, because {{fieldType.stored()}} > is executed before. > -- This message was sent by Atlassian Jira (v8.3.4#803005) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org