Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,4 +74,4 @@ module.exports = {
}
},
],
};
};
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,4 @@ data/db/
# Debug files
npm-debug.log*
yarn-debug.log*
yarn-error.log*
yarn-error.log*
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@
- Added dark-theme class to body
- Fixed footer links to match main layout
- Main layout:
- Added dark-theme class to body for consistent styling
- Added dark-theme class to body for consistent styling
2 changes: 1 addition & 1 deletion forum_improvement_plan.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,4 +86,4 @@ graph LR
* `public/css/styles.css`
* `public/css/laincore.css`
* `public/js/main.js`
* Potentially new CSS and JS files for specific forum functionality.
* Potentially new CSS and JS files for specific forum functionality.
2 changes: 1 addition & 1 deletion public/js/forum.js
Original file line number Diff line number Diff line change
Expand Up @@ -321,4 +321,4 @@ function addRandomGlitch() {
}

// Start random glitches
setTimeout(addRandomGlitch, 5000);
setTimeout(addRandomGlitch, 5000);
2 changes: 1 addition & 1 deletion public/js/laincore-loader.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,4 @@

// Log initialization
console.log('%c[wirebase.city] Laincore initialized', 'color: #00ff00; background: #0f0f0f;');
})();
})();
2 changes: 1 addition & 1 deletion public/js/laincore.js
Original file line number Diff line number Diff line change
Expand Up @@ -140,4 +140,4 @@ function createGlitchEffect() {

console.log("%c" + lainQuotes[Math.floor(Math.random() * lainQuotes.length)],
"color: #00ff00; background: #0f0f0f; padding: 10px; font-family: monospace; font-size: 14px;");
})();
})();
2 changes: 1 addition & 1 deletion public/js/login.js
Original file line number Diff line number Diff line change
Expand Up @@ -237,4 +237,4 @@ style.textContent = `
20%, 40%, 60%, 80% { transform: translateX(5px); }
}
`;
document.head.appendChild(style);
document.head.appendChild(style);
2 changes: 1 addition & 1 deletion public/js/register.js
Original file line number Diff line number Diff line change
Expand Up @@ -120,4 +120,4 @@ document.addEventListener('DOMContentLoaded', function() {
this.style.boxShadow = '';
});
Comment on lines 120 to 121
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Direct manipulation of styles in JavaScript, as seen here with transform and boxShadow, can lead to performance issues and makes the code harder to maintain. Consider using CSS for styling and transitions. For instance, define a CSS class with the desired styles and use JavaScript to add or remove this class based on user interactions. This approach not only improves performance by offloading rendering to the CSS engine but also enhances maintainability by keeping style definitions within CSS.

Example:

.register-button-hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3), 0 0 10px rgba(0, 255, 0, 0.3);
}
registerButton.addEventListener('mouseover', function() {
    this.classList.add('register-button-hover');
});
registerButton.addEventListener('mouseout', function() {
    this.classList.remove('register-button-hover');
});

}
});
});
2 changes: 1 addition & 1 deletion public/js/widgets.js
Original file line number Diff line number Diff line change
Expand Up @@ -229,4 +229,4 @@ function timeAgo(date) {

if (seconds < 10) return 'just now';
return Math.floor(seconds) + ' seconds ago';
}
}
2 changes: 1 addition & 1 deletion server/middleware/theme.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@ const themeMiddleware = (req, res, next) => {
next();
};

module.exports = themeMiddleware;
module.exports = themeMiddleware;
2 changes: 1 addition & 1 deletion server/models/Collection.js
Original file line number Diff line number Diff line change
Expand Up @@ -845,4 +845,4 @@ class Collection {
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The clearCache method could potentially lead to performance issues if the number of cache keys is large. Iterating through all keys and filtering them can be inefficient, especially if this method is called frequently. Consider optimizing this process by maintaining a dedicated list or pattern for collection-related keys, or by using more efficient cache querying methods if supported by the caching technology in use.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The method lacks error handling for potential failures in interacting with the cache, such as connection issues or permissions errors. This could lead to silent failures where the cache is not properly cleared, yet no error is reported. Enhancing error handling by catching and logging exceptions or errors during the cache deletion process would improve the robustness and reliability of the cache management system.

}

module.exports = Collection;
module.exports = Collection;
2 changes: 1 addition & 1 deletion server/models/MarketItem.js
Original file line number Diff line number Diff line change
Expand Up @@ -1212,4 +1212,4 @@ class MarketItem {
}
}

module.exports = MarketItem;
module.exports = MarketItem;
2 changes: 1 addition & 1 deletion server/models/Purchase.js
Original file line number Diff line number Diff line change
Expand Up @@ -361,4 +361,4 @@ class Purchase {
}
}

module.exports = Purchase;
module.exports = Purchase;
2 changes: 1 addition & 1 deletion server/models/ScrapyardItem.js
Original file line number Diff line number Diff line change
Expand Up @@ -833,4 +833,4 @@ ScrapyardItem.findFeaturedMarketplaceItems = async function(limit = 5) {
}
};

module.exports = ScrapyardItem;
module.exports = ScrapyardItem;
2 changes: 1 addition & 1 deletion server/models/Transaction.js
Original file line number Diff line number Diff line change
Expand Up @@ -352,4 +352,4 @@ class Transaction {
}
}

module.exports = Transaction;
module.exports = Transaction;
2 changes: 1 addition & 1 deletion server/models/User.js
Original file line number Diff line number Diff line change
Expand Up @@ -467,4 +467,4 @@ class User {
}
}

module.exports = User;
module.exports = User;
2 changes: 1 addition & 1 deletion server/models/WIRTransaction.js
Original file line number Diff line number Diff line change
Expand Up @@ -388,4 +388,4 @@ class WIRTransaction {
}
}

module.exports = WIRTransaction;
module.exports = WIRTransaction;
2 changes: 1 addition & 1 deletion server/models/Wishlist.js
Original file line number Diff line number Diff line change
Expand Up @@ -304,4 +304,4 @@ class Wishlist {
}
}

module.exports = Wishlist;
module.exports = Wishlist;
2 changes: 1 addition & 1 deletion server/routes/api.js
Original file line number Diff line number Diff line change
Expand Up @@ -247,4 +247,4 @@ router.get('/health', (req, res) => {
res.status(200).json({ status: 'ok', timestamp: new Date().toISOString() });
});

module.exports = router;
module.exports = router;
2 changes: 1 addition & 1 deletion server/routes/feed.js
Original file line number Diff line number Diff line change
Expand Up @@ -263,4 +263,4 @@ router.get('/subscribe', (req, res) => {
});
});

module.exports = router;
module.exports = router;
2 changes: 1 addition & 1 deletion server/routes/forum.js
Original file line number Diff line number Diff line change
Expand Up @@ -327,4 +327,4 @@ router.post('/thread/:id/reply', ensureAuthenticated, async (req, res) => {
}
});

module.exports = router;
module.exports = router;
2 changes: 1 addition & 1 deletion server/routes/market-api.js
Original file line number Diff line number Diff line change
Expand Up @@ -841,4 +841,4 @@ router.post('/wir/transfer', ensureApiAuth, async (req, res) => {
}
});

module.exports = router;
module.exports = router;
2 changes: 1 addition & 1 deletion server/routes/market.js
Original file line number Diff line number Diff line change
Expand Up @@ -836,4 +836,4 @@ router.post('/wir/convert', ensureAuthenticated, async (req, res) => {
}
});

module.exports = router;
module.exports = router;
2 changes: 1 addition & 1 deletion server/routes/user-market.js
Original file line number Diff line number Diff line change
Expand Up @@ -654,4 +654,4 @@ router.delete('/collections/:id/remove/:itemId', async (req, res) => {
}
});

module.exports = router;
module.exports = router;
2 changes: 1 addition & 1 deletion server/routes/users.js
Original file line number Diff line number Diff line change
Expand Up @@ -278,4 +278,4 @@ router.post('/change-password', ensureAuthenticated, async (req, res) => {
}
});

module.exports = router;
module.exports = router;
2 changes: 1 addition & 1 deletion server/utils/database.js
Original file line number Diff line number Diff line change
Expand Up @@ -180,4 +180,4 @@ initializeDatabase().catch(console.error);
module.exports = {
supabase,
supabaseAdmin
};
};
2 changes: 1 addition & 1 deletion server/utils/memory-monitor.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,4 @@ setInterval(() => {
memoryMonitor.logMemoryUsage();
}, 300000); // Every 5 minutes

module.exports = memoryMonitor;
module.exports = memoryMonitor;
2 changes: 1 addition & 1 deletion server/utils/passport-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,4 +58,4 @@ module.exports = function(passport) {
done(err, null);
}
});
};
};
2 changes: 1 addition & 1 deletion server/utils/view-cache.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,4 @@ const viewCacheMiddleware = (req, res, next) => {
next();
};

module.exports = viewCacheMiddleware;
module.exports = viewCacheMiddleware;
2 changes: 1 addition & 1 deletion server/views/about.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,4 @@
</div>
</div>
</div>
</div>
</div>
2 changes: 1 addition & 1 deletion server/views/compatibility.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -134,4 +134,4 @@
</div>
</div>
</div>
</div>
</div>
2 changes: 1 addition & 1 deletion server/views/components/flash-message.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@
onclick="this.parentElement.remove()">
<span aria-hidden="true">&times;</span>
</button>
</div>
</div>
2 changes: 1 addition & 1 deletion server/views/discover.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -79,4 +79,4 @@
{{/if}}
</div>
</div>
</div>
</div>
2 changes: 1 addition & 1 deletion server/views/error.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -123,4 +123,4 @@
background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJYAAACWCAMAAAAL34HQAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAMAUExURQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA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ASKk+rKhvXdXc7JoMvxen0sAoVBFrH67lUPbVg5l0WslrFcVJj3fRuWQ9UjVrtYnsqrQjHX9bpnO1icUq/WsQjVqPPquVhcF9aohFV2d+28sBKWWoE67sUdjYW4sMh2XFiZjsdCWGokdl0Xll0dDutLHSR33/VNWHZhnWKpnT+Jvg3Lro7DImCqK3R/3/VNWL6+/VgqI7fz6va+D8u1djgW6YAVXty/3nR9WObCMtXRWKogdYX3/euN6/uwvjOqo7GMKuz27w8ubV/77sZ9H1Z2YBEW6kDd37/fXG+urw/L7jsWy6nC7v7j/aL39fo+LLPvUKwc1+eHz6XurFn97yk7sEwdjAUu53X5+PjpB+vPz9lFpXsGi6WrQ7FUOeJlXMdSg1XycsuwqY7FIl6q0EZVxMpTZRnWpTocs2JVqrBEVcLKUhnVwViEpdpWPw6rSGVUR2Ph9x5iXIc/vCpSmdXBWGrqj+f51TesIlW6OhiLfHc91JxXEStPlawOx1Jcj8PKURmqE7BURK7CAlYOylCdjJWFKmBlqUx1LlYWqoBVorLVuVgZqgzWCJWtTsYaUdnqXKxBKledioW0MGk5rAzVdXU21jCV4zoTa5jKcZ2INUjluM7EGqTiCmZWdSLWEBVjQVRnooxiDVAxFqLymylj6YZKsTJUjKVTJtKVscapCIt8oxmn+mOsQSrC+hVdX2PVeVj9VIj1RVoA66s7F6ufauX+NapVpTEsP0t1EpafNa4zsfy8cZ2GNYw1pLOxBrHGdCrWMNW4zsQaphInY52GNUolTsMahuIKp2KNUYkzsUagxIlYg1TnY41RHY01SnU6giAIgiAIgiAIgv+Sr6/fDDjV1M7EKLAAAAAASUVORK5CYII=');
opacity: 0.6;
}
</style>
</style>
2 changes: 1 addition & 1 deletion server/views/faq.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -97,4 +97,4 @@
</div>
</div>
</div>
</div>
</div>
2 changes: 1 addition & 1 deletion server/views/feed/subscribe.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -121,4 +121,4 @@
</div>
</div>
</div>
</div>
</div>
2 changes: 1 addition & 1 deletion server/views/forum/category.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -284,4 +284,4 @@
<!-- Link to the new forum CSS file -->
<link rel="stylesheet" href="/css/forum.css">
<!-- Font Awesome for icons -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
2 changes: 1 addition & 1 deletion server/views/forum/index.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -381,4 +381,4 @@
<!-- Link to the new forum CSS file -->
<link rel="stylesheet" href="/css/forum.css">
<!-- Font Awesome for icons -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
2 changes: 1 addition & 1 deletion server/views/forum/new-thread.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -387,4 +387,4 @@
<!-- Link to the new forum CSS file -->
<link rel="stylesheet" href="/css/forum.css">
<!-- Font Awesome for icons -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
2 changes: 1 addition & 1 deletion server/views/forum/thread.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -422,4 +422,4 @@
<!-- Link to the new forum CSS file -->
<link rel="stylesheet" href="/css/forum.css">
<!-- Font Awesome for icons -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
2 changes: 1 addition & 1 deletion server/views/market/browse.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -1180,4 +1180,4 @@
.no-items-message p {
margin: 0 0 20px 0;
}
</style>
</style>
2 changes: 1 addition & 1 deletion server/views/market/collection.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -591,4 +591,4 @@
});
}
});
</script>
</script>
2 changes: 1 addition & 1 deletion server/views/market/collections.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -791,4 +791,4 @@
});
}
});
</script>
</script>
2 changes: 1 addition & 1 deletion server/views/market/index.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -789,4 +789,4 @@
grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}
}
</style>
</style>
2 changes: 1 addition & 1 deletion server/views/market/item.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -907,4 +907,4 @@
}, 3000);
}
});
</script>
</script>
2 changes: 1 addition & 1 deletion server/views/market/submit.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -819,4 +819,4 @@
.close-modal:hover {
color: #fff;
}
</style>
</style>
2 changes: 1 addition & 1 deletion server/views/market/user/collections.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -779,4 +779,4 @@
.notification.error {
border-left-color: var(--error-color);
}
</style>
</style>
2 changes: 1 addition & 1 deletion server/views/market/user/purchased.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -707,4 +707,4 @@
.notification.error {
border-left-color: var(--error-color);
}
</style>
</style>
2 changes: 1 addition & 1 deletion server/views/market/user/selling.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -384,4 +384,4 @@
margin: 0 0 20px 0;
color: var(--text-muted);
}
</style>
</style>
2 changes: 1 addition & 1 deletion server/views/market/user/wir.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -881,4 +881,4 @@
});
});
});
</script>
</script>
2 changes: 1 addition & 1 deletion server/views/market/user/wishlist.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -841,4 +841,4 @@
.notification.error {
border-left-color: var(--error-color);
}
</style>
</style>
2 changes: 1 addition & 1 deletion server/views/privacy.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -77,4 +77,4 @@
</div>
</div>
</div>
</div>
</div>
2 changes: 1 addition & 1 deletion server/views/profile/profile.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -471,4 +471,4 @@
}
}
});
</script>
</script>
2 changes: 1 addition & 1 deletion server/views/profile/terminal.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -363,4 +363,4 @@
overflow-x: auto;
margin: 5px 0;
}
</style>
</style>
2 changes: 1 addition & 1 deletion server/views/terms.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -58,4 +58,4 @@
</div>
</div>
</div>
</div>
</div>
2 changes: 1 addition & 1 deletion server/views/users/login.handlebars
Original file line number Diff line number Diff line change
Expand Up @@ -70,4 +70,4 @@
<div class="decoration circuit right"></div>
<div class="decoration static"></div>
</div>
</div>
</div>
Loading