I am creating custom task plugin. but i am getting error in log.
Error while running the 'Product Expiry Notification' schedule task. Not allowed
System.ApplicationException: Not allowed at Nop.Plugin.Misc.ProductExpireNotification.Services.ProductExpireNotificationService.CheckAccess(String usernameOrEmail, String userPassword) at Nop.Plugin.Misc.ProductExpireNotification.Services.ProductExpireNotificationService.GetPaymentMethod(String usernameOrEmail, String userPassword) at Nop.Plugin.Misc.ProductExpireNotification.Notification.Execute() at Nop.Services.Tasks.Task.Execute() in \Libraries\Nop.Services\Tasks\Task.cs:line 77
Please help me.
Thanks in advance.