Skip to content

Commit

Permalink
feature userAccessPolicy: polishing by feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
light-source committed Jan 8, 2025
1 parent a89bb51 commit f2282b5
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import type { IPAddress } from "@prosopo/types";
// Copyright 2021-2024 Prosopo (UK) Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -13,7 +14,6 @@
// limitations under the License.
import type RulesStorage from "../rule/storage/rulesStorage.js";
import type RequestInspector from "./requestInspector.js";
import type {IPAddress} from "@prosopo/types";

class RequestRulesInspector implements RequestInspector {
public constructor(private readonly rulesStorage: RulesStorage) {}
Expand Down
2 changes: 1 addition & 1 deletion packages/user-access-policy/src/rule/rule.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import type Config from "../config/config.js";
// Copyright 2021-2024 Prosopo (UK) Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -12,7 +13,6 @@
// See the License for the specific language governing permissions and
// limitations under the License.
import type Ip from "../ip/ip.js";
import type Config from "../config/config.js";

interface Rule {
isUserBlocked: boolean;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import * as util from "node:util";
import type { IPAddress } from "@prosopo/types";
import { Address4, Address6 } from "ip-address";
import type { ArgumentsCamelCase, Argv } from "yargs";
import type RulesStorage from "../../rulesStorage.js";
Expand All @@ -16,7 +17,6 @@ import type RulesStorage from "../../rulesStorage.js";
// See the License for the specific language governing permissions and
// limitations under the License.
import CommandBase from "./commandBase.js";
import type {IPAddress} from "@prosopo/types";

class MeasureFindCommand extends CommandBase {
public command = "measure-find";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import type { IPAddress } from "@prosopo/types";
// Copyright 2021-2024 Prosopo (UK) Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -20,7 +21,6 @@ import type RuleRecord from "./record/ruleRecord.js";
import type RulesStorage from "./rulesStorage.js";
import type SearchRuleFilterSettings from "./search/searchRuleFilterSettings.js";
import type SearchRuleFilters from "./search/searchRuleFilters.js";
import type { IPAddress } from "@prosopo/types";

class MongooseRulesStorage implements RulesStorage {
constructor(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
import type {IPAddress} from "@prosopo/types";
import type { IPAddress } from "@prosopo/types";

interface SearchRuleFilters {
userIpAddress?: IPAddress;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import type { IPAddress } from "@prosopo/types";
// Copyright 2021-2024 Prosopo (UK) Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
Expand All @@ -16,7 +17,6 @@ import type Ip from "../../../../../ip/ip.js";
import type Rule from "../../../../rule.js";
import type SearchRuleFilters from "../../searchRuleFilters.js";
import TestFindRuleBase from "../testFindRuleBase.js";
import type {IPAddress} from "@prosopo/types";

abstract class TestFindByIpBase extends TestFindRuleBase {
protected abstract getUserIpObject(): Ip;
Expand Down

0 comments on commit f2282b5

Please sign in to comment.