Skip to content

Commit 23e6626

Browse files
rainerstudiosclaude
andcommitted
Remove enhancement check from observer - let function handle it
The observer was checking if enhancement exists before calling the function, which prevented it from detecting when a different item was selected. Now the observer always calls enhanceInventoryItem() when panel is visible, and the function itself checks if the panel needs to be replaced based on assetid. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent a07b290 commit 23e6626

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

cs2-float-checker-release-v1.0.2/lib/inventoryEnhancer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ function initializeInventoryEnhancer() {
2424
const style = window.getComputedStyle(itemInfoPanel);
2525
const isVisible = style.display !== 'none' && parseFloat(style.opacity || '1') > 0;
2626

27-
if (isVisible && !itemInfoContent.querySelector('#cs2-inventory-enhancement')) {
27+
if (isVisible) {
2828
console.log(`🎯 Found visible item panel: iteminfo${i}`);
2929
enhanceInventoryItem(itemInfoContent, `iteminfo${i}`);
3030
}

0 commit comments

Comments
 (0)