Merge pull request #5360 from oneill/fix-exception-on-amf-export

Fixed NullReferenceException being thrown when exporting AMF file
This commit is contained in:
Lars Brubaker 2022-08-09 10:51:39 -07:00 committed by GitHub
commit fe5c44f8e0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -57,7 +57,7 @@ namespace MatterHackers.MatterControl.Library.Export
var firstItem = libraryItems.OfType<ILibraryAsset>().FirstOrDefault();
if (firstItem is ILibraryAsset libraryItem)
{
bool exportSuccessful = await MeshExport.ExportMesh(libraryItem, outputPath, null);
bool exportSuccessful = await MeshExport.ExportMesh(libraryItem, outputPath, progress);
if (exportSuccessful)
{
return null;