acbarbosa1964 / rawflickr

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

Calling TFlickrEx.Authorize w/ out a token fails to authorize #13

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
To reproduce the problem, simply create a TFlickrEx instance and 
callAuthorize w/ an empty token:

----------------------------------------
procedure ItWillFail;
  var Flickr: TFlickrEx;
begin
  Flickr := TFlickrEx.Create('valid api key', ''valid secret');
  if Flickr.Authorize('write', tmpToken) then
    ShowMessage('Authorized as ' + Flickr.User.UserName)
  else
    ShowMessage('Fail! Last response: '#OD#OA +
                Flickr.Auth.LastResponse);
end;
----------------------------------------

You should see the dialogs from DefaultAuthorize, etc. Instead, the call 
returns false as if the authorization had failed.

Original issue reported on code.google.com by sillyl...@gmail.com on 31 Mar 2009 at 11:03

GoogleCodeExporter commented 9 years ago
The problem was that DefaultAuthorize (and the calls to it from 
TFlickrEx.Authorize) 
were being IFDEFed out due to a missing {$DEFINE DELPHI}

This has been fixed and tested, and it will be up in the next commit.

Original comment by sillyl...@gmail.com on 31 Mar 2009 at 11:09

GoogleCodeExporter commented 9 years ago
Fix commited in r9

Original comment by sillyl...@gmail.com on 1 Apr 2009 at 1:21