Closed Bug 1078810 Opened 10 years ago Closed 6 years ago

Searching for bookmarks by url sometimes returns an empty list even when the bookmark exists.

Categories

(Add-on SDK Graveyard :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: emtwo, Unassigned)

References

Details

The following code works fine and prints an expected result: let bookmark = Bookmark({ title: "Test", url: "http://www.marinasamuel.com" }); save(bookmark); search({ url: "http://www.marinasamuel.com/" }).on("end", function (results) { console.log("results" + JSON.stringify(results)); }); However, this code doesn't work for some urls. E.g.: running the same code with "https://developer.mozilla.org/en-US/docs/Mozilla/Tech/Places/Retrieving_part_of_the_bookmarks_tree" as the url instead returns an empty list. I'm assuming this is not expected behaviour
OS: Mac OS X → All
Hardware: x86 → All
Flags: needinfo?(rFobic)
Flags: needinfo?(rFobic) → needinfo?(evold)
This should work: let bookmark = Bookmark({ title: "Test", url: "http://www.marinasamuel.com" }); save(bookmark).on("end", function() { search({ url: "http://www.marinasamuel.com/" }).on("end", function (results) { console.log("results" + JSON.stringify(results)); }); }); For more information see https://developer.mozilla.org/en-US/Add-ons/SDK/Low-Level_APIs/places_bookmarks
Status: NEW → RESOLVED
Closed: 10 years ago
Flags: needinfo?(evold)
Resolution: --- → WORKSFORME
If you use the example url provided by OP it doesn't work, it fails to match urls that have anything after the last slash. For example this works: https://bugzilla.mozilla.org/ But not this: https://bugzilla.mozilla.org/show_bug.cgi?id=1078810 As a workaround I use "query" to search for urls which works as expected.
Dave, could you please reopen this in light of my previous post?
Flags: needinfo?(dtownsend)
Status: RESOLVED → REOPENED
Resolution: WORKSFORME → ---
Flags: needinfo?(dtownsend)
Add-on SDK is no longer supported so resolving bugs as INCOMPLETE
Status: REOPENED → RESOLVED
Closed: 10 years ago6 years ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.