-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
✨ Enable parenthesized lists in search criteria [🚧 WIP: SequenceSet c…
…oercion] This affects search, uid_search, sort, uid_sort, thread, and uid_thread. Prior to this, sending a parenthesized list in the search criteria for any of these commands required the use of strings, which are converted to RawData, which has security implications with untrusted inputs. With this change, arrays will only be converted into SequenceSet when _every_ element in the array is a valid SequenceSet input. Otherwise, the array will be left alone, which allows us to send parenthesized lists without using strings and RawData. For example, some search criteria this change enables: * `["not", %w[flagged unread]]` converts to `not (flagged unread)`. * `["return", ["partial", 1..50]]` converts to `return (partial 1:50)`.
- Loading branch information
Showing
3 changed files
with
51 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters