Commit Graph

224 Commits

Author SHA1 Message Date
blagoev 115a2c9902 add deprecated warnings 2017-09-12 20:38:43 +03:00
blagoev 3fbd1291e1 fix _authenticate call to always pass the json object 2017-09-12 20:26:08 +03:00
Maximilian Alexander 78515e3b48 adding promisified apis 2017-09-12 20:10:52 +03:00
Kenneth Geisshirt eac393571d checkTypes() must only check the shortest array (#1297)
* Allow optional arguments when checking types
2017-09-12 15:17:59 +02:00
Kenneth Geisshirt 12a8cd5398 Adding missing TypeScript declaration of setFeatureToken (#1295)
* Adding missing TypeScript declaration of setFeatureToken
2017-09-12 14:28:16 +02:00
Ashwin Phatak 532f517ded Add Realm.deleteModel API (#573) 2017-09-12 14:45:36 +05:30
blagoev 9d02165db1 update typescript definitions 2017-09-11 15:50:44 +03:00
blagoev 0214dff951 fix possible hang on iOS 2017-09-11 15:50:44 +03:00
blagoev 43d8f2967f Fix typo 2017-09-11 15:50:44 +03:00
blagoev f8bac2d24a Fix Chrome Debugger for RN 2017-09-11 15:50:44 +03:00
blagoev e5ebb75d22 add typescript definitions 2017-09-11 15:50:44 +03:00
blagoev e1cebe073a add progress notifications api 2017-09-11 15:50:44 +03:00
Kenneth Geisshirt 38bceddfb1 Add missing TypeScript declaration (#1285)
* Adding missing TypeScript declaration
2017-09-08 10:19:13 +02:00
Ashwin Phatak 119cd79e5d Add Realm.deleteFile API (#363) 2017-09-07 10:12:59 +05:30
Kenneth Geisshirt 0c61716c08 Fix accessToken (#1275) 2017-09-01 11:53:52 +02:00
Kenneth Geisshirt 8d7eac1b65 Fix linter error (#1271) 2017-08-31 10:18:10 +02:00
Kristian Dupont 402bf48f88 Permissions api (#1244)
* Add basic permissions skeleton

* ...

* Update permissions api

* Wait for server to process management realm, add offer api

* Fix test of apply and get permissions, add offer test

* Accept permission offer

* Accept permission offer test

* Invalidate permission offer

* Add basic docs (still need some links etc)

* Refactor tests

* Only run permission tests where sync is enabled

* Use legal syntax for user name generation

* Add changelog entry

* Streamline permission tests

* Fix casing for access level names etc.

* Add basic definitions to index.d.ts

* Use settimeout for resolving promise from listener

* Complete typescript defs

* Improve docs

* Allow 'any' as default recipient in getGrantedPermissions

* Fix getSpecialPurposeRealm on iOS

* Response to PR comments

* Respond to PR comments

* Fix offer description

* Skip permission tests in chrome debugger :-/
2017-08-29 15:23:22 +02:00
Constantin S. Pan a84f1ed75d Allow all log levels in Realm.Sync.setLogLevels() 2017-08-29 10:37:29 +02:00
Kenneth Geisshirt 85fb49b354 Adding methods and property to manually control write transactions (#1216)
* Adding methods and property to manually control write transactions
2017-08-21 17:48:53 +02:00
Kenneth Geisshirt bd28c05936 Add shouldCompactOnLaunch option to configuration (#1209)
* Adding shouldCompactOnLaunch option to configuration
* Adding Realm.compact()
2017-08-18 14:22:29 +02:00
blagoev fad3b369dc fix bad term 2017-08-15 12:36:15 +03:00
blagoev 86999412f0 Depreciate setAccessToken
rename setAccessToken to setFeatureToken
expose both functions while setAccessToken is depreciated
Trim token argument string
2017-08-15 12:36:15 +03:00
Nikola Irinchev bbe62c361b
Don’t execute callback in Realm.open either 2017-07-18 11:28:33 +03:00
Nikola Irinchev bd10a6d8e0
Don’t invoke openAsync callback twice 2017-07-18 00:16:25 +03:00
Yavor Georgiev 5dd9264225
Add `Realm.empty` 2017-07-12 13:02:21 +02:00
Yavor Georgiev b1d23bb782
Realm.open and Realm.openAsync should try/catch opening the realm
and pass the error on to the promise and callback respectively so that it can be handled by the caller
2017-07-11 17:47:10 +02:00
Yavor Georgiev ab29ac4490 Fix linter issues (#1132) 2017-07-10 16:53:00 +02:00
Yavor Georgiev 1ba9b434b4 Add a new optional server parameter to User.adminUser (#1111)
* add a new optional server parameter to User.adminUser

This enables `User.openManagementRealm()` for admin token users.

* changelog

* API docs
2017-07-10 15:04:55 +02:00
blagoev 9ea5dd7f8c address review comments 2017-07-07 16:38:13 +03:00
blagoev 55c7c8f68c add TS definition for retrieveAccount 2017-07-07 10:31:29 +03:00
blagoev e31529397f Add tests for retrieveAccount method
fix admin-user-helper wait for admin to correctly wait
2017-07-07 10:31:29 +03:00
blagoev 73c861dc74 Remove method from list 2017-07-07 10:31:29 +03:00
blagoev 42e03e038d Add support for getting user id
For #1090
2017-07-07 10:31:29 +03:00
Marius Rackwitz 9e0a9a3bd3 Add support for accessing linking objects / backlinks (#1101)
* Add support for linkingObjects

* Test linkingObjects

* Borrow names helper from list tests

* include computed properties when serializing the schema for the RN debugger

* add API docs

* review comments

* Expose admin users to JS (#1100)

The JS binding used to conflate `SyncUser::is_admin()` with the user being created by calling `Realm.Sync.User.adminToken()`, but now that we expose a user’s role on the server under `is_admin()` this supposition is no longer correct.

#1097 attempted to fix one such case, but fixing it only uncovered another: in `UserClass<T>::all_users()`.  I’ve gone through all the callsites of `SyncUser::is_admin()` to make sure they don’t assume an admin token user.

* [1.8.3] Bump version

* add linkingObjects method to Realm.Object

* changelog
2017-06-29 11:59:10 +02:00
Yavor Georgiev 7ab3aff82f Expose admin users to JS (#1100)
The JS binding used to conflate `SyncUser::is_admin()` with the user being created by calling `Realm.Sync.User.adminToken()`, but now that we expose a user’s role on the server under `is_admin()` this supposition is no longer correct.

#1097 attempted to fix one such case, but fixing it only uncovered another: in `UserClass<T>::all_users()`.  I’ve gone through all the callsites of `SyncUser::is_admin()` to make sure they don’t assume an admin token user.
2017-06-27 20:32:34 +02:00
astigsen db4e184524 Added method to find index of object in collections (#1094)
* Added method to find index of object in collections

* rework as the indexOf method
2017-06-26 13:43:49 +02:00
Ari Lazier 726d02e78f Make ssl SyncConfiguration parameters optional 2017-06-20 10:13:33 -07:00
Yavor Georgiev 7086ed745f Do not throw when the Sync constructor isn’t there (#1086)
* Do not throw when the Sync constructor isn’t there

with unified packaging it’s there all the time now

Closes #1084
Fixes #996

* Fix running the sync tests when Sync is disabled
2017-06-20 15:40:54 +02:00
Maximilian Alexander 775bd8e2ff adding ts and package.json typings (#1076)
* adding ts and package.json typings

* remove DefinitelyTyped needed comments, we are hosting this ourselves

* adding licensing comments

* Added initial contribution support

Thanks @akim95

* changing year

* adding parameters

* Expand on collection typings

* update the windows pre-gyp script (#1072)

* Extract admin status from the refresh token (#1078)

* Extract admin status from the refresh token

Fixes #1063

* wire up rpc

* Make sure all callbacks enqueue on the Node.js event loop (#1079)

Fixes #1077

* Use an uncached realm instance for _waitForDownload (#1083)

Fixes #1061

* Add objectSchema method to Realm Object (#1055)

* Add objectSchema property to Realm Object

* fix

* fixes

* move typings under lib/

* changelog
2017-06-20 13:09:01 +02:00
Adam Fish 37dba6bb36 Add objectSchema method to Realm Object (#1055)
* Add objectSchema property to Realm Object

* fix
2017-06-20 11:42:43 +02:00
Yavor Georgiev 3e80683ad8 Extract admin status from the refresh token (#1078)
* Extract admin status from the refresh token

Fixes #1063

* wire up rpc
2017-06-17 16:59:15 +02:00
Kristian Dupont af72770094 Replace calls to sync.cleanup with sync.removealllisteners (#1066) 2017-06-14 12:54:47 +02:00
blagoev 416632c9ad Merge pull request #1062 from realm/blagoev/fix-RN-debug-with-vscode
Return debugger context if running on node in vscode debugger
2017-06-13 12:27:45 +03:00
blagoev 3764d4bf55 Return debugger context if running on node in vscode debugger
Experimental
2017-05-29 09:33:06 +03:00
blagoev 2390f9b084 Merge pull request #869 from realm/kd/fix-execution-context-detection
Update index.js to report missing react-native link
2017-05-29 09:00:16 +03:00
blagoev f4528ae6f5 fix for open async in RN Debug 2017-05-20 09:41:51 +03:00
blagoev cc2e685594 Fix for react-tests in Debug 2017-05-20 09:17:48 +03:00
blagoev a0f963775b Fix download api for RN
fix tests when run in RN
2017-05-17 16:09:19 +03:00
blagoev 0d3fbccbe1 forgotten file 2017-05-17 16:09:05 +03:00
blagoev 4b67d883b6 Add a fix for RN hang with promises 2017-05-17 16:08:42 +03:00