aboutsummaryrefslogtreecommitdiff
path: root/.config/BetterDiscord/plugins/PinDMs.plugin.js
diff options
context:
space:
mode:
Diffstat (limited to '.config/BetterDiscord/plugins/PinDMs.plugin.js')
-rw-r--r--.config/BetterDiscord/plugins/PinDMs.plugin.js14
1 files changed, 11 insertions, 3 deletions
diff --git a/.config/BetterDiscord/plugins/PinDMs.plugin.js b/.config/BetterDiscord/plugins/PinDMs.plugin.js
index 4fc8b3d..17fe404 100644
--- a/.config/BetterDiscord/plugins/PinDMs.plugin.js
+++ b/.config/BetterDiscord/plugins/PinDMs.plugin.js
@@ -9,7 +9,7 @@ var PinDMs = (_ => {
return class PinDMs {
getName () {return "PinDMs";}
- getVersion () {return "1.7.4";}
+ getVersion () {return "1.7.5";}
getAuthor () {return "DevilBro";}
@@ -17,7 +17,7 @@ var PinDMs = (_ => {
constructor () {
this.changelog = {
- "fixed":[["Sort by recent","Works again"]]
+ "fixed":[["All pinned","No longer acts weird if all DMs are pinned in a category"]]
};
this.patchedModules = {
@@ -145,7 +145,9 @@ var PinDMs = (_ => {
}
// Legacy
- load () {}
+ load () {
+ if (window.BDFDB && typeof BDFDB === "object" && BDFDB.loaded) BDFDB.PluginUtils.load(this);
+ }
start () {
if (!window.BDFDB) window.BDFDB = {myPlugins:{}};
@@ -355,6 +357,12 @@ var PinDMs = (_ => {
return rowHeightFunc(...args);
};
+ let renderRow = e.returnvalue.props.renderRow;
+ e.returnvalue.props.renderRow = (...args) => {
+ let row = renderRow(...args);
+ return row && row.key == "no-private-channels" ? null : row;
+ };
+
let renderSection = e.returnvalue.props.renderSection;
e.returnvalue.props.renderSection = (...args) => {
if (args[0].section != 0 && args[0].section != e.returnvalue.props.sections.length - 1) {