paulpflug / color-tabs

Adds colors to tabs..
MIT License
13 stars 7 forks source link

Uncaught TypeError: Cannot read property 'replace' of undefined #3

Closed ghost closed 9 years ago

ghost commented 9 years ago

[Enter steps to reproduce below:]

  1. ...
  2. ...

Atom Version: 1.0.0 System: Mac OS X 10.10.4 Thrown From: color-tabs package, v0.1.2

Stack Trace

Uncaught TypeError: Cannot read property 'replace' of undefined

At /Users/Nawks/.atom/packages/color-tabs/lib/color-tabs.coffee:20

TypeError: Cannot read property 'replace' of undefined
  at getCssElement (/Users/Nawks/.atom/packages/color-tabs/lib/color-tabs.coffee:20:14)
  at processPath (/Users/Nawks/.atom/packages/color-tabs/lib/color-tabs.coffee:64:16)
  at ColorTabs.module.exports.ColorTabs.color (/Users/Nawks/.atom/packages/color-tabs/lib/color-tabs.coffee:138:5)
  at atom-workspace.ColorTabs.disposables.add.atom.commands.add.color-tabs:color-current-tab (/Users/Nawks/.atom/packages/color-tabs/lib/color-tabs.coffee:130:14)
  at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app.asar/src/command-registry.js:241:29)
  at /Applications/Atom.app/Contents/Resources/app.asar/src/command-registry.js:3:61
  at KeymapManager.module.exports.KeymapManager.dispatchCommandEvent (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/atom-keymap/lib/keymap-manager.js:520:16)
  at KeymapManager.module.exports.KeymapManager.handleKeyboardEvent (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/atom-keymap/lib/keymap-manager.js:355:22)
  at HTMLDocument.module.exports.WindowEventHandler.onKeydown (/Applications/Atom.app/Contents/Resources/app.asar/src/window-event-handler.js:180:20)

Commands

  6x -0:33.8.0 application:new-file (atom-pane.pane.active)
     -0:27.9.0 settings-view:open (atom-text-editor.editor.is-focused)
     -0:01.1.0 color-tabs:color-current-tab (atom-text-editor.editor.is-focused)

Config

{
  "core": {
    "themes": [
      "darkula-ui",
      "darkula-syntax"
    ]
  },
  "color-tabs": {}
}

Installed Packages

# User
color-tabs, v0.1.2
ctags-status, v1.3.3
darkula-syntax, v0.3.0
darkula-ui, v0.1.0
emmet, v2.3.12
flex-tool-bar, v0.4.2
fonts, v0.5.0
minimap, v4.10.1
pigments, v0.8.2
tool-bar, v0.1.8
tool-bar-main, v0.0.8
toolbar-basic, v0.3.1
toolbar-iconshortcuts, v0.3.0

# Dev
No dev packages
paulpflug commented 9 years ago

yeah .. the problem with untitled tabs :smile: sadly it is not possible to color those (as they have no identifier, so coloring one would color others) I catched it in 0.1.3 thanks for reporting