git ssb

0+

ev / microbay



forked from Dominic / patchbay

Commit 722cbe26ce4fde5590323faa3abb3fc2b1db248a

Merge branch 'error-handling'

Dominic Tarr committed on 7/25/2016, 5:16:52 AM
Parent: 85234427043c9af0029e4c1e29b958c46b9b09a3
Parent: 3c5dd43a2f6adbcaaad339b0a31e11f7d87eec1f

Files changed

index.jschanged
modules/message-confirm.jschanged
index.jsView
@@ -1,5 +1,13 @@
11 var h = require('hyperscript')
2+
3+window.addEventListener('error', function onError(e) {
4+ document.body.appendChild(h('div.error',
5+ h('h1', e.message),
6+ h('big', h('code', e.filename + ':' + e.lineno)),
7+ h('pre', e.error ? (e.error.stack || e.error.toString()) : e.toString())))
8+})
9+
210 var u = require('./util')
311 var pull = require('pull-stream')
412 var combine = require('depject')
513 var fs = require('fs')
modules/message-confirm.jsView
@@ -15,9 +15,10 @@
1515 var lb = lightbox()
1616 document.body.appendChild(lb)
1717
1818 var okay = h('button', 'okay', {onclick: function () {
19- publish(content); lb.remove(); cb(null, content)
19+ lb.remove()
20+ publish(content, cb)
2021 }})
2122
2223 var cancel = h('button', 'cancel', {onclick: function () {
2324 lb.remove()

Built with git-ssb-web