Built motion from commit 9d1906d1.|2.5.40
[motion2.git] / server / services / ami / fax / util / gs.js
1 // *************************************************************************
2 // *                                                                       *
3 // * xCALLY Motion -  The Omnichannel Contact Center                       *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved                     *
5 // *                                                                       *
6 // *************************************************************************
7 // *                                                                       *
8 // * Email: info@xcally.com                                                *
9 // * Website: https://www.xcally.com                                       *
10 // *                                                                       *
11 // *************************************************************************
12 // *                                                                       *
13 // * The SOFTWARE PRODUCT is protected by copyright laws and international *
14 // * copyright treaties, as well as other intellectual property laws and   *
15 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                         *
16 // *                                                                       *
17 // *************************************************************************
18 var _0xf251=['../../../../config/logger','bluebird','exec','info','Exec\x20gs','inspect'];(function(_0x5c1746,_0x2d083c){var _0x394a50=function(_0x7c70f4){while(--_0x7c70f4){_0x5c1746['push'](_0x5c1746['shift']());}};_0x394a50(++_0x2d083c);}(_0xf251,0x126));var _0x1f25=function(_0x28beaf,_0x122959){_0x28beaf=_0x28beaf-0x0;var _0x2df201=_0xf251[_0x28beaf];return _0x2df201;};'use strict';var util=require('util');var logger=require(_0x1f25('0x0'))('fax');var BPromise=require(_0x1f25('0x1'));var exec=require('child_process')[_0x1f25('0x2')];exports['execute']=function(_0x2d2c9e){return new BPromise(function(_0x1f7748,_0x11530c){exec(_0x2d2c9e,function(_0xd3bee2,_0x4a6b75,_0x32a061){logger[_0x1f25('0x3')](_0x1f25('0x4'),_0x4a6b75);if(_0xd3bee2){logger['info'](_0x1f25('0x4'),'\x20Error\x20:',util[_0x1f25('0x5')](_0xd3bee2,{'showHidden':![],'depth':null}),_0x4a6b75,_0x32a061);_0x11530c(_0xd3bee2);}_0x1f7748(_0x4a6b75);});});};