remove lockfile during publish

This commit is contained in:
Kayla Man 2022-09-16 21:00:03 +08:00
parent 563515c0e6
commit c2d9ef859e

View file

@ -1,4 +1,5 @@
import pyblish.api
from openpype.pipeline.workfile.lock_workfile import(
is_workfile_lock_enabled,
remove_workfile_lock
@ -28,6 +29,7 @@ class SaveCurrentScene(pyblish.api.ContextPlugin):
return
active_project = legacy_io.active_project()
# remove lockfile before saving
if is_workfile_lock_enabled("maya", active_project):
remove_workfile_lock(current)
self.log.info("Saving current file..")