File tree Expand file tree Collapse file tree 5 files changed +17
-14
lines changed Expand file tree Collapse file tree 5 files changed +17
-14
lines changed Original file line number Diff line number Diff line change 1
- exports = module . exports = require ( 'backends-web' ) ;
2
- exports . chrome = require ( 'backends/chrome-fs' ) ;
1
+ var backends = module . exports = require ( 'backends-web' ) ;
2
+ backends . push ( require ( 'backends/chrome-fs' ) ) ;
Original file line number Diff line number Diff line change 1
- exports . github = require ( 'backends/github' )
1
+ var backends = module . exports = [ ] ;
2
+ backends . push ( require ( 'backends/github' ) ) ;
2
3
if ( window . indexedDB ) {
3
- exports . idb = require ( 'backends/indexed-db' ) ;
4
+ backends . push ( require ( 'backends/indexed-db' ) ) ;
5
+ }
6
+ if ( window . openDatabase ) {
7
+ backends . push ( require ( 'backends/websql' ) ) ;
8
+ }
9
+ if ( window . localStorage ) {
10
+ backends . push ( require ( 'backends/local-storage' ) ) ;
4
11
}
5
- // if (window.openDatabase) {
6
- // exports.sql = require('backends/websql');
7
- // }
8
- // if (window.localStorage) {
9
- // exports.local = require('backends/local-storage');
10
- // }
Original file line number Diff line number Diff line change @@ -26,9 +26,8 @@ module.exports.configs = configs;
26
26
27
27
// Create a repo instance from a config
28
28
function createRepo ( config ) {
29
- var names = Object . keys ( backends ) ;
30
- for ( var i = 0 , l = names . length ; i < l ; i ++ ) {
31
- var repo = backends [ names [ i ] ] . createRepo ( config ) ;
29
+ for ( var i = 0 , l = backends . length ; i < l ; i ++ ) {
30
+ var repo = backends [ i ] . createRepo ( config ) ;
32
31
if ( repo ) return repo ;
33
32
}
34
33
}
Original file line number Diff line number Diff line change 1
- module . exports = [ ] ;
1
+ module . exports = [
2
+ require ( 'runtimes/file-export' ) ,
3
+ require ( 'runtimes/http-server' )
4
+ ] ;
File renamed without changes.
You can’t perform that action at this time.
0 commit comments