66
77const fs = require ( 'fs' )
88 , dsConfig = require ( '../config/appsettings.json' )
9- , examplesApi = require ( '../config/examplesApi .json' )
9+ , examplesApi = require ( '../config/examplesAPI .json' )
1010 , documentationTopic = 'auth-code-grant-node'
1111 ;
1212
@@ -69,7 +69,7 @@ commonControllers.switchApi = (req, res) => {
6969 if ( chosenApi == "eSignature" ) {
7070 apiChoice . examplesApi . isESignatureApi = true ;
7171 let data = JSON . stringify ( apiChoice ) ;
72- fs . writeFile ( "config/examplesApi .json" , data , function ( err ) {
72+ fs . writeFile ( "config/examplesAPI .json" , data , function ( err ) {
7373 if ( err ) throw err ;
7474 console . log ( 'complete' ) ;
7575 }
@@ -78,7 +78,7 @@ commonControllers.switchApi = (req, res) => {
7878 else if ( chosenApi == "rooms" ) {
7979 apiChoice . examplesApi . isRoomsApi = true ;
8080 let data = JSON . stringify ( apiChoice ) ;
81- fs . writeFile ( "config/examplesApi .json" , data , function ( err ) {
81+ fs . writeFile ( "config/examplesAPI .json" , data , function ( err ) {
8282 if ( err ) throw err ;
8383 console . log ( 'complete' ) ;
8484 }
@@ -87,7 +87,7 @@ commonControllers.switchApi = (req, res) => {
8787 else if ( chosenApi == "click" ) {
8888 apiChoice . examplesApi . isClickApi = true ;
8989 let data = JSON . stringify ( apiChoice ) ;
90- fs . writeFile ( "config/examplesApi .json" , data , function ( err ) {
90+ fs . writeFile ( "config/examplesAPI .json" , data , function ( err ) {
9191 if ( err ) throw err ;
9292 console . log ( 'complete' ) ;
9393 }
@@ -96,7 +96,7 @@ commonControllers.switchApi = (req, res) => {
9696 else if ( chosenApi == "monitor" ) {
9797 apiChoice . examplesApi . isMonitorApi = true ;
9898 let data = JSON . stringify ( apiChoice ) ;
99- fs . writeFile ( "config/examplesApi .json" , data , function ( err ) {
99+ fs . writeFile ( "config/examplesAPI .json" , data , function ( err ) {
100100 if ( err ) throw err ;
101101 console . log ( 'complete' ) ;
102102 }
@@ -105,7 +105,7 @@ commonControllers.switchApi = (req, res) => {
105105 else if ( chosenApi == "admin" ) {
106106 apiChoice . examplesApi . isAdminApi = true ;
107107 let data = JSON . stringify ( apiChoice ) ;
108- fs . writeFile ( "config/examplesApi .json" , data , function ( err ) {
108+ fs . writeFile ( "config/examplesAPI .json" , data , function ( err ) {
109109 if ( err ) throw err ;
110110 console . log ( 'complete' ) ;
111111 }
0 commit comments