serverdensity/puppet-serverdensity — pull request #35 by jake-minted (2014-12-06 00:25:25+00:00)
Title: Fix agent_key function

Agent_key function errors out on api-version 2, with no providor or
providor_id specified.

This results in ```list``` being ```nil```, and checking ```list``` with
```list.length``` returns a NoMethodError(undefined method for
nil:NilClass).

In case a second check for "nil" was really needed, checking the
variable ```list``` for ```empty?``` was added.