Skip to content

Commit

Permalink
Bug #15 alchemy returns blank score
Browse files Browse the repository at this point in the history
  • Loading branch information
kotarf committed May 18, 2013
1 parent 70830bf commit cda00bc
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 12 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,4 @@ Version history:
"0.0.1.0", Check if sorting is in progress before attaching create listener in enable auto sort
"0.0.1.1", Imports will temporarily disable automatic sort, visit sort will not move if bookmarking is in progress, clear all interval alarms because duplicates were noticed on Chromium
"0.0.1.2", New logo, promo images. Switched to MIT license.
"0.0.1.3", Bug #15
21 changes: 11 additions & 10 deletions bookmarksorter.js
Original file line number Diff line number Diff line change
Expand Up @@ -434,13 +434,14 @@
// If not, make an API request.
me.alchemyCategory(url, function(data, textStatus, jqXHR) {

var category = data.category;
var title = undefined;
var status = data.status;
var statusInfo = data.statusInfo;
var category = data.category,
title = undefined,
status = data.status,
statusInfo = data.statusInfo,
score = data.score;

// Check the status first
if (status === me.config.okStatus) {
if (status === me.config.okStatus && score && category) {
// If the score of the result is horrible, redo the whole thing using the baseUrl (if not already using it)
var score = data.score;

Expand Down Expand Up @@ -516,13 +517,13 @@
console.log("Making a TITLE request for - ", url);
me.alchemyTitle(baseUrl, function(data, textStatus, jqXHR) {

var title = data.title;
var category = undefined;
var status = data.status;
var statusInfo = data.statusInfo;
var title = data.title,
category = undefined,
status = data.status,
statusInfo = data.statusInfo;

// Check the status first
if (status === me.config.okStatus) {
if (status === me.config.okStatus && title) {

// Cache the title
me.cacheTitle(cachedData, baseUrl, title);
Expand Down
2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "Smart Bookmark Sorter",
"version": "0.0.1.2",
"version": "0.0.1.3",
"manifest_version": 2,
"description": "Sort bookmarks based on their title, category and frequency of use",
"icons": { "128": "images/logo_128x128.png", "48" : "images/logo_48x48.png", "16" : "images/logo_16x16.png"},
Expand Down
2 changes: 1 addition & 1 deletion popup.html
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ <h2 class="demoHeaders">API Key</h2>
</div>
<div id="tabs-5">
<div id="container">
<p>Version 0.0.1.1</p>
<p>Version 0.0.1.3</p>
<p>Powered by</p>
<a href="http://alchemyapi.com" target="_blank"><img src="images/alchemyAPI.jpg" alt="AlchemyAPI Logo"></a>
<a href="http://jqueryui.com" target="_blank"><img src="images/jquery_ui_logo.png" alt="JQuery UI Logo"></a>
Expand Down

0 comments on commit cda00bc

Please sign in to comment.