Browse Source

Skipping server data block

Co-authored-by: David Sehnal <dsehnal@users.noreply.github.com>
Aliaksei 2 years ago
parent
commit
a7181e865c
1 changed files with 3 additions and 0 deletions
  1. 3 0
      src/mol-plugin-state/formats/volume.ts

+ 3 - 0
src/mol-plugin-state/formats/volume.ts

@@ -205,6 +205,9 @@ export const DscifProvider = DataFormatProvider({
         const volumes: StateObjectSelector<PluginStateObject.Volume.Data>[] = [];
         let i = 0;
         for (const block of blocks) {
+            // Skip "server" data block.
+            if (block.header.toUpperCase() === 'SERVER') continue;
+            
             const entryId = Array.isArray(params?.entryId) ? params?.entryId[i] : params?.entryId;
             if (block.categories['volume_data_3d_info']?.rowCount > 0) {
                 volumes.push(b.apply(StateTransforms.Volume.VolumeFromDensityServerCif, { blockHeader: block.header, entryId }).selector);