diff --git a/LightcordApi/src/alias/react-dom.ts b/LightcordApi/src/alias/react-dom.ts index 570edc3..0af534f 100644 --- a/LightcordApi/src/alias/react-dom.ts +++ b/LightcordApi/src/alias/react-dom.ts @@ -4,7 +4,7 @@ import { ReactDOMSelector } from "./selectors" window.ReactDOM = (window["Reac"+"tDOM"] || // If in Lightcord (()=>{ // If in Standard BetterDiscord try{ - return window.BdApi.findModule(ReactDOMSelector as any) + return window.BdApi.ReactDOM }catch(e){ return null } @@ -19,7 +19,7 @@ window.ReactDOM = (window["Reac"+"tDOM"] || // If in Lightcord })() || (()=>{ // If in EnhancedDiscord try{ - return window.EDApi.findModule(ReactDOMSelector as any) + return window.EDApi.ReactDOM }catch(e){ return null } diff --git a/LightcordApi/src/alias/react.ts b/LightcordApi/src/alias/react.ts index 8bc5928..d5911a0 100644 --- a/LightcordApi/src/alias/react.ts +++ b/LightcordApi/src/alias/react.ts @@ -3,7 +3,7 @@ import { ReactSelector } from "./selectors"; window.React = (window.React || // If in Lightcord (()=>{ // If in Standard BetterDiscord try{ - return window.BdApi.findModule(ReactSelector as any) + return window.BdApi.React }catch(e){ return null } @@ -18,7 +18,7 @@ window.React = (window.React || // If in Lightcord })() || (()=>{ // If in EnhancedDiscord try{ - return window.EDApi.findModule(ReactSelector as any) + return window.EDApi.React }catch(e){ return null } diff --git a/LightcordApi/src/index.ts b/LightcordApi/src/index.ts index 029a11c..0f22332 100644 --- a/LightcordApi/src/index.ts +++ b/LightcordApi/src/index.ts @@ -48,6 +48,8 @@ declare global { EDApi: typeof bandagedbdApi.BdApi } var Lightcord:LightcordGlobal + var BdApi: typeof bandagedbdApi.BdApi + var EDApi: typeof bandagedbdApi.BdApi } export default LightcordApi