Skip to content

Commit

Permalink
Remove console logs and empty className
Browse files Browse the repository at this point in the history
  • Loading branch information
TyHil committed Jul 10, 2024
1 parent b3d12e2 commit 4f723fe
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 9 deletions.
4 changes: 0 additions & 4 deletions src/background/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,18 +95,14 @@ realBrowser.tabs.onActivated.addListener(async () => {
});

realBrowser.runtime.onInstalled.addListener(async () => {
console.log('hey from install listener');
const currentPermissions: { permissions: string[]; origins: string[] } =
await realBrowser.permissions.getAll();
console.log(`current permissions: ${currentPermissions.origins}`);
if (
neededOrigins.filter(
(origin) => !currentPermissions.origins.includes(origin),
).length !== 0
) {
console.log('opening permission request');
const popupURL = await realBrowser.runtime.getURL('tabs/permissions.html');
console.log(popupURL);
realBrowser.windows.create({
url: popupURL,
type: 'popup',
Expand Down
4 changes: 0 additions & 4 deletions src/popup.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,14 @@ import { neededOrigins } from '~data/config';

const realBrowser = process.env.PLASMO_BROWSER === 'chrome' ? chrome : browser;
async function checkPermissions() {
console.log('hey from permission check');
const currentPermissions: { permissions: string[]; origins: string[] } =
await realBrowser.permissions.getAll();
console.log(`current permissions: ${currentPermissions.origins}`);
if (
neededOrigins.filter(
(origin) => !currentPermissions.origins.includes(origin),
).length !== 0
) {
console.log('opening permission request');
const popupURL = await realBrowser.runtime.getURL('tabs/permissions.html');
console.log(popupURL);
realBrowser.windows.create({
url: popupURL,
type: 'popup',
Expand Down
2 changes: 1 addition & 1 deletion src/tabs/permissions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ function PermissionsPls() {

return (
<div>
<h1 className="">Sk.edge needs permissions to run</h1>
<h1>Sk.edge needs permissions to run</h1>
<p>
We need access to Schedule Planner and the sources we get our data from.
</p>
Expand Down

0 comments on commit 4f723fe

Please sign in to comment.