diff options
author | Philipp Oeser <info@graphics-engineer.com> | 2021-09-15 12:51:52 +0300 |
---|---|---|
committer | Philipp Oeser <info@graphics-engineer.com> | 2021-09-15 13:09:23 +0300 |
commit | 429136c89f653a0aee3253dae7ea90d524d11003 (patch) | |
tree | a7b061b6155d4a4a83bf314242d465fc2b71a51c /release | |
parent | e6ca0545904fe4236be9960fdb3c2760092582a5 (diff) |
Fix Asset Browser cannot open containing file anymore
In {rB9cff9f9f5df0} asset_library was renamed → asset_library_ref.
Missed to update this in assets.py.
Differential Revision: https://developer.blender.org/D12497
Diffstat (limited to 'release')
-rw-r--r-- | release/scripts/startup/bl_operators/assets.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/release/scripts/startup/bl_operators/assets.py b/release/scripts/startup/bl_operators/assets.py index 8c76018b7a1..b241e537c38 100644 --- a/release/scripts/startup/bl_operators/assets.py +++ b/release/scripts/startup/bl_operators/assets.py @@ -85,9 +85,9 @@ class ASSET_OT_open_containing_blend_file(Operator): @classmethod def poll(cls, context): asset_file_handle = getattr(context, 'asset_file_handle', None) - asset_library = getattr(context, 'asset_library', None) + asset_library_ref = getattr(context, 'asset_library_ref', None) - if not asset_library: + if not asset_library_ref: cls.poll_message_set("No asset library selected") return False if not asset_file_handle: @@ -100,13 +100,13 @@ class ASSET_OT_open_containing_blend_file(Operator): def execute(self, context): asset_file_handle = context.asset_file_handle - asset_library = context.asset_library + asset_library_ref = context.asset_library_ref if asset_file_handle.local_id: self.report({'WARNING'}, "This asset is stored in the current blend file") return {'CANCELLED'} - asset_lib_path = bpy.types.AssetHandle.get_full_library_path(asset_file_handle, asset_library) + asset_lib_path = bpy.types.AssetHandle.get_full_library_path(asset_file_handle, asset_library_ref) self.open_in_new_blender(asset_lib_path) wm = context.window_manager |