Skip to content

Commit

Permalink
registerProtocol has been deprecated
Browse files Browse the repository at this point in the history
  • Loading branch information
zcbenz authored and Nathan Sobo committed Oct 16, 2015
1 parent 9354b86 commit 70fc6dd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/browser/atom-protocol-handler.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class AtomProtocolHandler

# Creates the 'atom' custom protocol handler.
registerAtomProtocol: ->
protocol.registerProtocol 'atom', (request) =>
protocol.registerFileProtocol 'atom', (request, callback) =>
relativePath = path.normalize(request.url.substr(7))

if relativePath.indexOf('assets/') is 0
Expand All @@ -41,4 +41,4 @@ class AtomProtocolHandler
filePath = path.join(loadPath, relativePath)
break if fs.statSyncNoException(filePath).isFile?()

new protocol.RequestFileJob(filePath)
callback(filePath)

0 comments on commit 70fc6dd

Please sign in to comment.