         fileServer.serve req, res, (err) =>
           if err?
             res.writeHead 200, {'Content-Type': 'text/html'}
-            res.end template
+            res.end content
       .resume()
     .listen port, hostname
 
     server.addListener 'connection', (socket) =>
       sockets.push socket
 
-    url = "http://#{hostname}:#{port}"
-    if !isRestart and atom.config.get 'broadcast.automaticallyOpenInBrowser'
-      @openUrlInBrowser url
-
-    console.log "Broadcast started at #{url}"
+    return url
 
   @stop: ->
     if server is null

        content = content.replace /[\w-\.\/]+node_modules\/roaster/g, ''
    else
      content = '<pre>' + editor.getText?() + '</pre>'
    template = template.replace '{CONTENT}', content

    fileServer = new nodeStatic.Server filePath

    hostname = atom.config.get('broadcast.hostname') or 'localhost'
    port = atom.config.get('broadcast.port') or 8000

    http = require 'http'
    server = http.createServer (req, res) =>

  urlToCheatSheetSite: 'https://raw.githubusercontent.com/arvida/emoji-cheat-sheet.com/master/public/graphics/emojis'

  @start: ->
    isRestart = server?
    if isRestart
      @stop()

    content = @getContent()
    url = @startServer content

    if !isRestart and atom.config.get 'broadcast.automaticallyOpenInBrowser'
      @openUrlInBrowser url

    console.log "Broadcast started at #{url}"

  @getContent: ->
    editor = atom.workspace.activePaneItem
    if editor[0]?
      content = editor[0].outerHTML
