Skip to content

Add contains operator (case-insensitive substring)#3560

Closed
ajpallares wants to merge 1 commit into
pallares/json-logic-iteration-mapping-operatorsfrom
pallares/sdk-4348-android-contains-operator
Closed

Add contains operator (case-insensitive substring)#3560
ajpallares wants to merge 1 commit into
pallares/json-logic-iteration-mapping-operatorsfrom
pallares/sdk-4348-android-contains-operator

Conversation

@ajpallares

@ajpallares ajpallares commented Jun 8, 2026

Copy link
Copy Markdown
Member

Checklist

  • If applicable, unit tests
  • If applicable, create follow-up issues for purchases-ios and hybrids

Motivation

Adds the khepri-specific contains operator for case-insensitive substring checks in workflow predicates (SDK-4348). Companion iOS PR: RevenueCat/purchases-ios#6943

Description

Implemented as function(haystack, needle) with locale-independent lowercasing; non-string haystacks return false, with no json-logic falsy guard on the haystack. Twenty shared predicate fixtures added (fixture count 347 → 367).

Co-authored-by: Cursor <cursoragent@cursor.com>
@ajpallares

Copy link
Copy Markdown
Member Author

Closing this PR. We've decided to only implement operators that are part of the JSON Logic specification in the SDKs. contains is a khepri-specific operator and is not part of the JSON Logic spec, so we will not be adding it to the SDK.

@ajpallares ajpallares closed this Jun 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr:feat A new feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant