danriegsecker / as3flickrlib

Automatically exported from code.google.com/p/as3flickrlib
0 stars 0 forks source link

invokeMethod adds too many blank / null params into the query. #34

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Using $flickrService.photos.search to perform a tag search.

var tags:String = $flashvars.tags || "seattle";
var sort:String = $flashvars.sort || "date-posted-desc";
var license:String = "1,2,3,4,5";

$flickrService.photos.search(null, tags, null, null, null, null, null,
null, license, sort);

2. Watch the request in firebug and notice there are a lot of blank params.
3. Response doesn't match the request.

What is the expected output? What do you see instead?

Expected: 

http://api.flickr.com/services/rest/?api_key=19f009910a77e59597766e606e5fb439&me
thod=flickr.photos.search&tags=zachgraves&license=1,2,3,4,5&sort=date-posted-des
c&per_page=100&page=1&

Actual result:

http://api.flickr.com/services/rest/?api_key=19f009910a77e59597766e606e5fb439&me
thod=flickr.photos.search&user_id=&tags=zachgraves&tag_mode=null&text=null&min_u
pload_date=&max_upload_date=&min_taken_date=&max_taken_date=&license=1,2,3,4,5&s
ort=date-posted-desc&privacy_filter=&bbox=&accuracy=&safe_search=&content_type=&
machine_tags=&machine_tag_mode=&group_id=&contacts=&woe_id=&place_id=&media=&has
_geo=&lat=&lon=&radius=&radius_units=&extras=&per_page=100&page=1&

What version of the product are you using? On what operating system?
r37, flash player 9.0.124.0, os x, firefox 3.0.3

Please provide any additional information below.

I fixed it by patching MethodGroupHelper.as, the diff is attached. 

(I also took the liberty to fix the extra & at the end of the query string.

Original issue reported on code.google.com by zagra...@gmail.com on 4 Oct 2008 at 1:31

Attachments:

GoogleCodeExporter commented 9 years ago
Not sure if I was clear enough before... If you check the responses in each of 
the
URLs above, the photo list is pretty different. Meaning the null/blank params 
are
having an effect on the search results.

Original comment by zagra...@gmail.com on 4 Oct 2008 at 5:13