Make final return statement be useful
authorLars Wirzenius <liw@liw.fi>
Thu, 2 Aug 2012 23:04:26 +0000 (00:04 +0100)
committerLars Wirzenius <liw@liw.fi>
Thu, 2 Aug 2012 23:04:26 +0000 (00:04 +0100)
commita6ea6470afe8766b9c6d892ce05444ab69d2c7fa
tree0ef6217052e978585c6668acd7748c4a26b731be
parente0e4d4f88c17ce02fd8e53e23a34c89369c6c222
Make final return statement be useful

The final return statement was not useful: it was dead code, and was never
executed, since both the try and except branches of the exception
handling were exiting the method before the final return statement
was reached.

Change the method to follow the structure of the get_data method,
by assigning the return value of urlopen into a variable, which the
final return statement then returns.
jenkinsapi/jenkinsbase.py