If you are noticing delays on activation of locks, there are a couple of things you can do to prevent it from happening.
1. Enable Speed Optimization
Photolock has an "Optimize Speed" feature available under "Configuration" settings. It is highly recommended to enable this setting to improve the user experience.
2. Optimize Your Site Speed
To maximize the effectiveness of Photolock™, we recommend optimizing your site to an effective load-time under 3 seconds.
The most common way to increase site speed is compressing digital assets and photography. You can use a free tool like www.tinyjpg.com
to compress your images yourself and upload them to your online store or website.
If your site has a longer load time and image compression does not solve the problem, we suggest that you speak with a developer team or Shopify Expert (like Pasilobus) to optimize your pages.
3. Disable Asynchronous Loading
Photolock™ is loaded asynchronously, meaning that it loads after the rest of your page elements to ensure speed and not cause any conflict with any other apps on your store. If your site's load time is longer than average, this will cause slight delays in Photolock™ actions.
While we always recommend optimizing your site for speed, if you are not able to do so, you can choose to disable asynchronous loading so Photolock™ will be forced to load before all your page elements and no delay will occur.
To disable asynchronous loading you need to make a small change in your connector script. You can locate the connector script in your web site's layout file, which should have been placed just before the tag. It looks something like this:
<script src="https://www.photolock.io/lock.js?shop=www.myonlinestore.com" async defer></script>
You will want to remove async defer attributes from this script and it should look like this after:
<script src="https://www.photolock.io/lock.js?shop=www.myonlinestore.com" ></script>
Once you save changes in your code editor, asynchronous loading should be disabled.