Removed .js from all imports to smooth ts migration

This commit is contained in:
ThaumRystra
2023-09-28 21:27:05 +02:00
parent 97790264d3
commit ece4a9391a
485 changed files with 1844 additions and 1843 deletions

View File

@@ -1,8 +1,8 @@
import MONGO_OPERATORS from '/imports/constants/MONGO_OPERATORS.js';
import MONGO_OPERATORS from '/imports/constants/MONGO_OPERATORS';
const hasAny = function(values){
for (let value of values){
if (this.has(value)){
const hasAny = function (values) {
for (let value of values) {
if (this.has(value)) {
return true;
}
}
@@ -11,11 +11,11 @@ const hasAny = function(values){
// Returns a Set of fields the modifier changes
// The set has been extended with the "hasAny" function
export default function getModifierFields (modifier) {
export default function getModifierFields(modifier) {
let fields = new Set();
for (let operator of MONGO_OPERATORS){
if (modifier[operator]) for (let field in modifier[operator]){
for (let operator of MONGO_OPERATORS) {
if (modifier[operator]) for (let field in modifier[operator]) {
const indexOfDot = field.indexOf('.');
if (indexOfDot !== -1) {
field = field.substring(0, indexOfDot);