Преглед на файлове

Non-standard params check in viewer.toJSON

master
Palash Bansal преди 11 месеца
родител
ревизия
9fa02f41a2
No account linked to committer's email address
променени са 1 файла, в които са добавени 2 реда и са изтрити 0 реда
  1. 2
    0
      src/viewer/ThreeViewer.ts

+ 2
- 0
src/viewer/ThreeViewer.ts Целия файл

@@ -1164,6 +1164,8 @@ export class ThreeViewer extends EventDispatcher<Record<IViewerEventTypes, IView
* @returns {any} - Serializable JSON object.
*/
toJSON(binary = true, pluginFilter?: string[]): ISerializedViewerConfig {
if (typeof binary !== 'boolean') binary = true // its a meta, ignore it
if (pluginFilter !== undefined && !Array.isArray(pluginFilter)) pluginFilter = undefined // non standard param.
const meta = getEmptyMeta()
const data: ISerializedViewerConfig = Object.assign({
...this._defaultConfig,

Loading…
Отказ
Запис