Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

reuse .load method

  • Loading branch information...
commit 21c6ae8ed19e068d0b5e98f68c8422e96fa72d24 1 parent 25ff78f
Petr Janda authored

Showing 1 changed file with 2 additions and 9 deletions. Show diff stats Hide diff stats

  1. +2 9 lib/view.js
11 lib/view.js
@@ -92,16 +92,9 @@ View.prototype.build = function(reload, callback) {
92 92 return;
93 93 }
94 94
95   - storage.loadView(this.uid, function(data) {
96   - // Apply data, loaded from snapshot.
97   - if(data) {
98   - self.data = data.data;
99   - self.lastEvent = data.lastEvent
100   - }
101   -
102   - // Update data and lastEvent, load data from repo just for newer events.
  95 + this.load(function(data) {
103 96 loadEvents();
104   - })
  97 + })
105 98 }
106 99
107 100 View.prototype.load = function(callback) {

0 comments on commit 21c6ae8

Please sign in to comment.
Something went wrong with that request. Please try again.