mirror of
https://github.com/outline/outline.git
synced 2025-12-17 08:44:27 -06:00
fix: Disable Notion import when env is not available (#8761)
This commit is contained in:
@@ -81,7 +81,12 @@ export const Notion = observer(() => {
|
||||
}, [t, appName, oauthError]);
|
||||
|
||||
return (
|
||||
<Button type="submit" onClick={() => redirectTo(authUrl)} neutral>
|
||||
<Button
|
||||
type="submit"
|
||||
onClick={() => redirectTo(authUrl)}
|
||||
disabled={!env.NOTION_CLIENT_ID}
|
||||
neutral
|
||||
>
|
||||
{t("Import")}…
|
||||
</Button>
|
||||
);
|
||||
|
||||
@@ -5,8 +5,8 @@ import environment from "@server/utils/environment";
|
||||
import { CannotUseWithout } from "@server/utils/validators";
|
||||
|
||||
class NotionPluginEnvironment extends Environment {
|
||||
@IsOptional()
|
||||
@Public
|
||||
@IsOptional()
|
||||
public NOTION_CLIENT_ID = this.toOptionalString(environment.NOTION_CLIENT_ID);
|
||||
|
||||
@IsOptional()
|
||||
|
||||
Reference in New Issue
Block a user