Fix function complexity
Move digest auth to seperate class
Gemfile.lock