Remove unused code in provider.

This code was intended to to be used at a later and we are not sure when we will use this. This code seems to give NilClass exceptions at some cases. So it is safe to get rid of this code now and use it later if we really need it.