forked from CIT/Vmeda.Online
		
	Merge pull request #2066 from dpalou/MOBILE-3118
MOBILE-3118 siteplugins: Stringify objects copied from otherdata
This commit is contained in:
		
						commit
						152bbca149
					
				@ -445,14 +445,25 @@ export class CoreSitePluginsProvider {
 | 
				
			|||||||
            // Include only the properties specified in the array.
 | 
					            // Include only the properties specified in the array.
 | 
				
			||||||
            for (const i in useOtherData) {
 | 
					            for (const i in useOtherData) {
 | 
				
			||||||
                const name = useOtherData[i];
 | 
					                const name = useOtherData[i];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					                if (typeof otherData[name] == 'object' && otherData[name] !== null) {
 | 
				
			||||||
 | 
					                    // Stringify objects.
 | 
				
			||||||
 | 
					                    args[name] = JSON.stringify(otherData[name]);
 | 
				
			||||||
 | 
					                } else {
 | 
				
			||||||
                    args[name] = otherData[name];
 | 
					                    args[name] = otherData[name];
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
        } else {
 | 
					        } else {
 | 
				
			||||||
            // Add all the data to args.
 | 
					            // Add all the data to args.
 | 
				
			||||||
            for (const name in otherData) {
 | 
					            for (const name in otherData) {
 | 
				
			||||||
 | 
					                if (typeof otherData[name] == 'object' && otherData[name] !== null) {
 | 
				
			||||||
 | 
					                    // Stringify objects.
 | 
				
			||||||
 | 
					                    args[name] = JSON.stringify(otherData[name]);
 | 
				
			||||||
 | 
					                } else {
 | 
				
			||||||
                    args[name] = otherData[name];
 | 
					                    args[name] = otherData[name];
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        return args;
 | 
					        return args;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user