iPhone 3G error 1015 fixed

I’ve been messing around with our old iPhone 3G a while ago and I did something to brick it. Now I can’t get it restored back. Every time I try, I get the 1015 error. From what I’ve read, it has something to do with the baseband version not matching with what iTunes is expecting….