mirror of
https://github.com/ynput/ayon-core.git
synced 2026-01-01 08:24:53 +01:00
remove unecessary code
This commit is contained in:
parent
b3bedc7ce7
commit
9a9c29c70c
1 changed files with 6 additions and 11 deletions
|
|
@ -18,7 +18,7 @@ from openpype.client import (
|
|||
create_project,
|
||||
)
|
||||
from openpype.pipeline import AvalonMongoDB
|
||||
from openpype.settings import get_project_settings, get_anatomy_settings
|
||||
from openpype.settings import get_project_settings
|
||||
from openpype.modules.kitsu.utils.credentials import validate_credentials
|
||||
|
||||
|
||||
|
|
@ -262,25 +262,20 @@ def write_project_to_op(project: dict, dbcon: AvalonMongoDB) -> UpdateOne:
|
|||
# Update Zou
|
||||
gazu.project.update_project(project)
|
||||
|
||||
project_attributes = get_anatomy_settings(project_name)['attributes']
|
||||
if "x" in project["resolution"]:
|
||||
resolutionWidth = int(project["resolution"].split("x")[0])
|
||||
resolutionHeight = int(project["resolution"].split("x")[1])
|
||||
else:
|
||||
resolutionWidth = project_attributes['resolutionWidth']
|
||||
resolutionHeight = project_attributes['resolutionHeight']
|
||||
|
||||
# Update data
|
||||
project_data.update(
|
||||
{
|
||||
"code": project_code,
|
||||
"fps": float(project["fps"]),
|
||||
"resolutionWidth": resolutionWidth,
|
||||
"resolutionHeight": resolutionHeight,
|
||||
"zou_id": project["id"],
|
||||
}
|
||||
)
|
||||
|
||||
proj_res = project["resolution"]
|
||||
if "x" in proj_res:
|
||||
project_data['resolutionWidth'] = int(proj_res.split("x")[0])
|
||||
project_data['resolutionHeight'] = int(proj_res.split("x")[1])
|
||||
|
||||
return UpdateOne(
|
||||
{"_id": project_doc["_id"]},
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue