fix: Introduce formattedData for connections to separate types
This commit is contained in:

committed by
Ömer Faruk Aydın

parent
39b50fc0d3
commit
719a948134
@@ -22,15 +22,15 @@ const createAuthDataResolver = async (
|
||||
const appData = App.findOneByKey(connection.key);
|
||||
|
||||
const appInstance = new appClass(appData, {
|
||||
consumerKey: connection.data.consumerKey,
|
||||
consumerSecret: connection.data.consumerSecret,
|
||||
consumerKey: connection.formattedData.consumerKey,
|
||||
consumerSecret: connection.formattedData.consumerSecret,
|
||||
});
|
||||
|
||||
const authLink = await appInstance.authenticationClient.createAuthData();
|
||||
|
||||
await connection.$query().patch({
|
||||
data: {
|
||||
...connection.data,
|
||||
formattedData: {
|
||||
...connection.formattedData,
|
||||
...authLink,
|
||||
},
|
||||
});
|
||||
|
Reference in New Issue
Block a user