{"action":"created","issue":{"url":"https://api.github.com/repos/invertase/react-native-firebase/issues/1506","repository_url":"https://api.github.com/repos/invertase/react-native-firebase","labels_url":"https://api.github.com/repos/invertase/react-native-firebase/issues/1506/labels{/name}","comments_url":"https://api.github.com/repos/invertase/react-native-firebase/issues/1506/comments","events_url":"https://api.github.com/repos/invertase/react-native-firebase/issues/1506/events","html_url":"https://github.com/invertase/react-native-firebase/issues/1506","id":361736256,"node_id":"MDU6SXNzdWUzNjE3MzYyNTY=","number":1506,"title":"When key in \"!=\" and \"array_contains\" where operator turn out error!!! ","user":{"login":"Luktm","id":24861458,"node_id":"MDQ6VXNlcjI0ODYxNDU4","avatar_url":"https://avatars0.githubusercontent.com/u/24861458?v=4","gravatar_id":"","url":"https://api.github.com/users/Luktm","html_url":"https://github.com/Luktm","followers_url":"https://api.github.com/users/Luktm/followers","following_url":"https://api.github.com/users/Luktm/following{/other_user}","gists_url":"https://api.github.com/users/Luktm/gists{/gist_id}","starred_url":"https://api.github.com/users/Luktm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Luktm/subscriptions","organizations_url":"https://api.github.com/users/Luktm/orgs","repos_url":"https://api.github.com/users/Luktm/repos","events_url":"https://api.github.com/users/Luktm/events{/privacy}","received_events_url":"https://api.github.com/users/Luktm/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2018-09-19T12:57:32Z","updated_at":"2018-09-20T16:22:01Z","closed_at":"2018-09-19T13:30:44Z","author_association":"NONE","body":"### Issue\r\n\r\nWhere operator turn out error when key in \"!=\" and \"array_contains\". I do not know which part i did wrong.\r\n\r\n```\r\nimport React, {Component} from 'react';\r\nimport {\r\n    ScrollView,\r\n    TouchableOpacity,\r\n    Text,\r\n    View,\r\n    TouchableWithoutFeedback\r\n} from 'react-native';\r\nimport firebase from 'react-native-firebase';\r\n\r\nclass ChatTicketList extends Component {\r\n\r\n    state = {\r\n        tickets: {}\r\n    };\r\n\r\n    componentWillMount() {\r\n        firebase.firestore().collection('tickets').where('fruit', 'array_contains', 'apple')\r\n            .onSnapshot(collection => {\r\n                const tickets = {};\r\n\r\n                collection.forEach(doc => {\r\n                    tickets[doc.id] = doc.data();\r\n                });\r\n                this.setState({tickets})\r\n            });\r\n    }\r\n}\r\n```\r\n\r\nFirebase firestore database:\r\n![firestore-array-data](https://user-images.githubusercontent.com/24861458/45754948-9e5af700-bc4f-11e8-9f2d-a22b5761736c.JPG)\r\n\r\nError Get From Emulator:\r\n![operator-error](https://user-images.githubusercontent.com/24861458/45754814-415f4100-bc4f-11e8-88f2-a480e4711872.PNG)\r\n\r\nFirebase cloud firestore documentation: \r\n![firebase-doc-array-contains](https://user-images.githubusercontent.com/24861458/45755648-93a16180-bc51-11e8-9505-093c8a73493e.JPG)\r\n\r\n\r\n### Environment\r\n\r\n1. Application Target Platform: Android\r\n\r\n<!--- (e.g. iOS, Android, Both) --->\r\n\r\n2. Development Operating System: Windows 10\r\n\r\n<!--- (e.g. macOS Sierra, Windows 10) --->\r\n\r\n3. Build Tools: Android SDK Version 27.0.3\r\n\r\n<!--- (Xcode or Android Studio version, iOS or Android SDK version - if relevant) --->\r\n\r\n4. `React Native` version: 0.55.4\r\n\r\n<!--- (e.g. 0.52.0) --->\r\n\r\n5. `React Native Firebase` Version: 4.3.8\r\n\r\n<!--- (e.g. 4.3.0) --->\r\n\r\n6. `Firebase` Module: database\r\n\r\n<!--- (e.g. database, auth, messaging, analytics etc - or N/A if not applicable) --->\r\n\r\n7. Are you using `typescript`? no\r\n\r\n<!--- yes/no --->\r\n\r\n---"},"comment":{"url":"https://api.github.com/repos/invertase/react-native-firebase/issues/comments/423245694","html_url":"https://github.com/invertase/react-native-firebase/issues/1506#issuecomment-423245694","issue_url":"https://api.github.com/repos/invertase/react-native-firebase/issues/1506","id":423245694,"node_id":"MDEyOklzc3VlQ29tbWVudDQyMzI0NTY5NA==","user":{"login":"Salakar","id":5347038,"node_id":"MDQ6VXNlcjUzNDcwMzg=","avatar_url":"https://avatars0.githubusercontent.com/u/5347038?v=4","gravatar_id":"","url":"https://api.github.com/users/Salakar","html_url":"https://github.com/Salakar","followers_url":"https://api.github.com/users/Salakar/followers","following_url":"https://api.github.com/users/Salakar/following{/other_user}","gists_url":"https://api.github.com/users/Salakar/gists{/gist_id}","starred_url":"https://api.github.com/users/Salakar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Salakar/subscriptions","organizations_url":"https://api.github.com/users/Salakar/orgs","repos_url":"https://api.github.com/users/Salakar/repos","events_url":"https://api.github.com/users/Salakar/events{/privacy}","received_events_url":"https://api.github.com/users/Salakar/received_events","type":"User","site_admin":false},"created_at":"2018-09-20T16:22:01Z","updated_at":"2018-09-20T16:22:01Z","author_association":"MEMBER","body":"@Luktm @felixchan `v5.0.0-rc4` has just been published with firestore `array-contains` filtering support.\r\n\r\nNote that the correct usage is with a dash (`array-contains`), not an underscore (`array_contains`).\r\n\r\n---\r\nLoving `react-native-firebase` and the support we provide? Please consider supporting us with any of the below:\r\n\r\n  - 👉  Back financially via [Open Collective](https://opencollective.com/react-native-firebase/donate)  \r\n  - 👉  Follow [`React Native Firebase`](https://twitter.com/rnfirebase) and [`Invertase`](https://twitter.com/invertaseio) on Twitter \r\n  - 👉  Star this repo on GitHub ⭐️"}}
{"actor":{"display_login":"Salakar"}}