Firebase Android:使用户名唯一
app : { users: { "some-user-uid": { email: "test@test.com" username: "myname" } }}
{ "rules": { ".read": true, ".write": true, "users": { "$uid": { ".write": "auth !== null && auth.uid === $uid", ".read": "auth !== null && auth.provider === 'password'", "username": {".validate": "!root.child('users').child(newData.child('username').val()).exists()"} } } }}
拉丁的传说
慕码人8056858
相关分类