Make get method to to return default value if empty

Based on #3 Implemented test for the same.