Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

declare `titleSplit` variable

  • Loading branch information...
commit eb261158315faf8d7836e28aaa81883cbd516bfb 1 parent ed2c2de
@ipmb authored
Showing with 9 additions and 8 deletions.
  1. +9 −8 tinycon.js
View
17 tinycon.js
@@ -134,15 +134,16 @@
};
var updateTitle = function(num) {
- if (options.fallback) {
- var numText = num > 0 ? '('+num+') ' : '';
- if (options.fallbackMethod === 'static') {
- document.title = numText + originalTitle;
- } else if (options.fallbackMethod === 'dynamic') {
- titleSplit = document.title.split(titleRegEx);
- document.title = numText + titleSplit.slice(-1);
+ if (options.fallback) {
+ var titleSplit,
+ numText = num > 0 ? '('+num+') ' : '';
+ if (options.fallbackMethod === 'static') {
+ document.title = numText + originalTitle;
+ } else if (options.fallbackMethod === 'dynamic') {
+ titleSplit = document.title.split(titleRegEx);
+ document.title = numText + titleSplit.slice(-1);
+ }
}
- }
};
var drawBubble = function(context, num, colour) {
Please sign in to comment.
Something went wrong with that request. Please try again.