function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
jdlforcejdlforce 

Why am I getting this when trying to deploy to production?

Problem: Unknown constructor 'ProductsToAssets_NexPATH.ProductsToAssets_NexPATH()'

 

Any idea why? This is the first time I run into this problem. My testMethod covers my code 100% but when I try to deploy to production I get that error message.

 

Thanks, JD 

Best Answer chosen by Admin (Salesforce Developers) 
jdlforcejdlforce

Thank you for your reply.

I found the problem. I never use "_" when naming my pages and/or classes but I did it this time. After renaming my class removing the underscore everything was fine.

Again, this only happened when trying to deploy code to production.

 

JD 

All Answers

S_LieS_Lie
can you copy the constructor code ?
jdlforcejdlforce

Thank you for your reply.

I found the problem. I never use "_" when naming my pages and/or classes but I did it this time. After renaming my class removing the underscore everything was fine.

Again, this only happened when trying to deploy code to production.

 

JD 

This was selected as the best answer