Problem solved.
Here′s the solution:
I have the wprocket plugin installed on my website and i have the cloduflare cdn configured as well. The problem layed on the fact that i put the cloudflare nameservers on the wprocket plugin and enabled the cdn function on the plugin itself. That is not how it′s supposed to be done and it ended up causing this issue. Hope it can help someone else in the future.