File tree Expand file tree Collapse file tree 6 files changed +2188
-2188
lines changed
Expand file tree Collapse file tree 6 files changed +2188
-2188
lines changed Original file line number Diff line number Diff line change @@ -75,29 +75,29 @@ func (dbx *apiImpl) TokenRevoke() (err error) {
7575 if dbx .Config .Verbose {
7676 log .Printf ("body: %s" , body )
7777 }
78- if resp .StatusCode != http .StatusOK {
79- if resp .StatusCode == http .StatusConflict {
80- var apiError TokenRevokeAPIError
81- err = json .Unmarshal (body , & apiError )
82- if err != nil {
83- return
84- }
85- err = apiError
86- return
87- }
88- var apiError dropbox.APIError
89- if resp .StatusCode == http .StatusBadRequest {
90- apiError .ErrorSummary = string (body )
91- err = apiError
92- return
93- }
78+ if resp .StatusCode == http .StatusOK {
79+ return
80+ }
81+ if resp .StatusCode == http .StatusConflict {
82+ var apiError TokenRevokeAPIError
9483 err = json .Unmarshal (body , & apiError )
9584 if err != nil {
9685 return
9786 }
9887 err = apiError
9988 return
10089 }
90+ var apiError dropbox.APIError
91+ if resp .StatusCode == http .StatusBadRequest {
92+ apiError .ErrorSummary = string (body )
93+ err = apiError
94+ return
95+ }
96+ err = json .Unmarshal (body , & apiError )
97+ if err != nil {
98+ return
99+ }
100+ err = apiError
101101 return
102102}
103103
You can’t perform that action at this time.
0 commit comments