diff --git a/README.md b/README.md index 6a4dfe7..04fc392 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,9 @@ This extension hopes to clean the HTML that Adobe Edge Reflow makes in order to provide a better starting spot for hand coded projects. +## Author +The author of this extension is Terrence Ryan (https://github.com/tpryan). I merely added a workaround to get the CSS extractor to work again with a new version of Brackets/Adobe Edge Code CC. + ## Abilities Currently the project does the following: diff --git a/reflowCSSExtractor.js b/reflowCSSExtractor.js index bead16f..b6b6192 100644 --- a/reflowCSSExtractor.js +++ b/reflowCSSExtractor.js @@ -741,6 +741,9 @@ var ReflowCSSExtractor = function (csscontent) { }; this.hexToRGB = function (hex) { + if (hex == null) { + return {r: 0, g:0, b:0}; + } // Expand shorthand form (e.g. "03F") to full form (e.g. "0033FF") var shorthandRegex = /^#?([a-f\d])([a-f\d])([a-f\d])$/i; hex = hex.replace(shorthandRegex, function (m, r, g, b) { @@ -799,4 +802,4 @@ var ReflowCSSExtractor = function (csscontent) { }; -}; \ No newline at end of file +};