Should I get rid of my ipad because im trying to beat a porn addiction and I can take it to bed?

No. Use this marvel to get the help you deserve: an evaluation by a well trained psychiatrist.
Yes, for now. You should seek help for porn addiction. You will be told to get rid off the ipad for now. Hopefully. You may be able to set your self a strict time and safe site plan when your recovery is stable and your internet activites can be resumed.