Fixed serviceProvider issue

Fixed an issue regarding the serviceProvider