Fix the “Cannot read properties of undefined (reading 'replace')” error
Use this guide if Bulk Mockup Photoshop Plugin stops during generation and shows the error Cannot read properties of undefined (reading 'replace'). This usually happens when there is a problem with your template setup, input folders, or file names.
Before you start, make sure you are using Adobe Photoshop CC 2022 or newer and that Bulk Mockup Photoshop Plugin is fully loaded inside Photoshop.
Step 1: Open Bulk Mockup Photoshop Plugin
Open Adobe Photoshop.
Go to Plugins > Bulk Mockup.
Wait for the plugin panel to load fully.
Step 2: Check your template folder
In the plugin panel, review your PSD Templates Folder.
Make sure the folder only contains valid Photoshop template files.
Remove hidden, duplicate, or unsupported files if you see them.
Open one template and confirm the smart object layer you want to replace is set up correctly.
Your template should be clean and ready for batch processing before you start the run again.
Step 3: Check your design folder
Review the folder used for your Design File Folder or Design Location.
Make sure your design files are supported and not corrupted.
Remove extra files that should not be processed.
If your workflow uses a design smart object layer, make sure the target layer name is correct.
Incorrect inputs in this folder can stop the generation process.
Step 4: Check file and folder names
Rename files if they contain unusual symbols or special characters.
Use simple names with letters, numbers, dashes, or underscores.
If you are using multiple smart objects or subfolders, make sure the names match exactly.
Name mismatches can cause processing errors during replacement steps.
Step 5: Check your export folder
Select your Export Folder or Export Location again.
Make sure the folder still exists and is accessible.
Choose a simple local folder if needed and test the run again.
This helps rule out path or permission issues.
Step 6: Run the batch again
Go back to Bulk Mockup Photoshop Plugin.
Confirm your template, design, and export folders are correct.
Click Start Generating or Run Bulk Mockup.
Test with one template and one design first if the error continues.
What to do if the error still appears
If the same error shows again, test with a very simple setup: one PSD template, one design file, and one empty export folder. If that works, add your other files back in small batches until you find the file or template causing the issue.
Watch Similar videos:
Use Cases:
Fixing failed bulk generation runs
Checking template and design folder problems
Troubleshooting smart object replacement errors
Need More Help?
If you have questions about export folder settings or encounter any issues, contact the Bulk Mockup support team at [email protected].