mirror of
https://github.com/chrisnov-it/quantumbotx.git
synced 2026-08-01 05:07:45 +00:00
aa984c4909
- Update `.gitignore` to include `lab/` for backtesting and raw data. - Refactor `app.py` to improve error handling and logging. - Remove deprecated files: `core/bot_logic.py`, `core/bots/base_bot.py`, `core/bots/manager.py`, `core/db/database.py`, `core/routes/api_analysis.py`, `core/routes/api_bots_analysis.py`, `core/strategies/logic_ma.py`, `core/strategies/logic_rsi.py`. - Modify multiple files to enhance bot management, routing, and strategy handling. - Update JavaScript and HTML templates for better UI and functionality.
50 lines
1007 B
JavaScript
50 lines
1007 B
JavaScript
/**
|
|
* @fileoverview Rule to disallow empty static blocks.
|
|
* @author Sosuke Suzuki
|
|
*/
|
|
"use strict";
|
|
|
|
//------------------------------------------------------------------------------
|
|
// Rule Definition
|
|
//------------------------------------------------------------------------------
|
|
|
|
/** @type {import('../types').Rule.RuleModule} */
|
|
module.exports = {
|
|
meta: {
|
|
type: "suggestion",
|
|
|
|
docs: {
|
|
description: "Disallow empty static blocks",
|
|
recommended: true,
|
|
url: "https://eslint.org/docs/latest/rules/no-empty-static-block",
|
|
},
|
|
|
|
schema: [],
|
|
|
|
messages: {
|
|
unexpected: "Unexpected empty static block.",
|
|
},
|
|
},
|
|
|
|
create(context) {
|
|
const sourceCode = context.sourceCode;
|
|
|
|
return {
|
|
StaticBlock(node) {
|
|
if (node.body.length === 0) {
|
|
const closingBrace = sourceCode.getLastToken(node);
|
|
|
|
if (
|
|
sourceCode.getCommentsBefore(closingBrace).length === 0
|
|
) {
|
|
context.report({
|
|
node,
|
|
messageId: "unexpected",
|
|
});
|
|
}
|
|
}
|
|
},
|
|
};
|
|
},
|
|
};
|