Only add href if link is self link is set
Prevent "empty" keys being added to JSON output