Printer plugin not working 2nd time in iOS

import { Printer, PrintOptions } from '@ionic-native/printer/ngx';

this.printer.print(html, options).then(onSuccess, onError);

Works perfectly in android and 1st time in iOS.
After calling print 2nd time of app lifecycle I get this error:

This application is modifying the autolayout engine from a background thread after the engine was accessed from the main thread. This can lead to engine corruption and weird crashes.

***** Terminating app due to uncaught exception ‘NSInternalInconsistencyException’, reason: ‘Modifications to the layout engine must not be performed from a background thread after it has been accessed from the main thread.’**


Ionic CLI : 5.4.16
Ionic Framework : @ionic/angular 6.1.10
@angular-devkit/build-angular : 13.3.5
@angular-devkit/schematics : 13.2.6
@angular/cli : 13.3.5
@ionic/angular-toolkit : 6.1.0


Capacitor CLI : 3.5.1
@capacitor/core : 3.5.1


Cordova CLI : 11.0.0
Cordova Platforms : none
Cordova Plugins : no whitelisted plugins (1 plugins total)


cordova-res : 0.15.4
native-run : 1.5.0