Fix T93357: crash when opening search menu

This is the same fix as in rBde35a90f9f56d3ff3ac80c13bf1ae296853ba877
but for the blender-v3.0-release branch.
This commit is contained in:
2021-11-25 00:03:41 +01:00
parent a9642f8d61
commit 8f2db94627

View File

@@ -693,6 +693,9 @@ static bool asset_bundle_install_poll(bContext *C)
{
/* This operator only works when the asset browser is set to Current File. */
const SpaceFile *sfile = CTX_wm_space_file(C);
if (sfile == nullptr) {
return false;
}
if (!ED_fileselect_is_local_asset_library(sfile)) {
return false;
}