Release 0.8.3

This commit is contained in:
Kevin Jahns 2016-01-15 03:46:55 +01:00
parent ece8268e44
commit 102555a3b0
3 changed files with 9 additions and 4 deletions

2
dist

@ -1 +1 @@
Subproject commit a77eb39218a5815854daa07373f7f4597c3b9cb9
Subproject commit 3b8e148d8fee752b6318df2b940316c77936b812

View File

@ -1,6 +1,6 @@
{
"name": "yjs",
"version": "0.8.3",
"version": "0.8.4",
"description": "A framework for real-time p2p shared editing on arbitrary complex data types",
"main": "./src/y.js",
"scripts": {

View File

@ -93,8 +93,9 @@ function Y (opts/* :YOptions */) /* :Promise<YConfig> */ {
Y.sourceDir = opts.sourceDir
return Y.requestModules(modules).then(function () {
return new Promise(function (resolve) {
var yconfig = new YConfig(opts, function () {
yconfig.db.whenUserIdSet(function () {
var yconfig = new YConfig(opts)
yconfig.db.whenUserIdSet(function () {
yconfig.init(function () {
resolve(yconfig)
})
})
@ -111,6 +112,10 @@ class YConfig {
constructor (opts, callback) {
this.db = new Y[opts.db.name](this, opts.db)
this.connector = new Y[opts.connector.name](this, opts.connector)
this.options = opts
}
init (callback) {
var opts = this.options
var share = {}
this.share = share
this.db.requestTransaction(function * requestTransaction () {