Skip to content

Commit

Permalink
properly access what the service vendor is for check phone numbers UI
Browse files Browse the repository at this point in the history
  • Loading branch information
engelhartrueben committed Sep 20, 2024
1 parent 40a5122 commit 0bfa10f
Showing 1 changed file with 6 additions and 12 deletions.
18 changes: 6 additions & 12 deletions src/containers/AdminPhoneNumberInventory.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,17 +33,6 @@ import { Snackbar } from "@material-ui/core";
import { Alert } from "@material-ui/lab";
import { getConfig } from "../server/api/lib/config";

// fake service is allowed for easier testing
const isTwilio = (
getConfig("DEFAULT_SERVICE") === "twilio"
);

const isFakeservice = (
getConfig("DEFAULT_SERVICE") === "fakeservice"
);

const isTwilioOrFakeservice = isTwilio || isFakeservice;

const inlineStyles = {
column: {
textOverflow: "ellipsis",
Expand Down Expand Up @@ -384,11 +373,16 @@ class AdminPhoneNumberInventory extends React.Component {
render() {
const {
phoneNumberCounts,
pendingPhoneNumberJobs
pendingPhoneNumberJobs,
serviceVendor: { name }
} = this.props.data.organization;

const { filters } = this.state;

const isTwilio = name == "twilio";
const isFakeservice = name == "fakeservice";
const isTwilioOrFakeservice = isTwilio || isFakeservice;

// Push rows for pending jobs as a simple visual indication that counts are
// being updated.
// In the future we may want to add a header with more data about pending
Expand Down

0 comments on commit 0bfa10f

Please sign in to comment.