Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-Authored-By: Aleh Zasypkin <[email protected]>
  • Loading branch information
legrego and azasypkin authored Feb 5, 2020
1 parent 73cc266 commit 35b81ea
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ describe('CopySavedObjectsToSpaceService', () => {
it('registers the CopyToSpaceSavedObjectsManagementAction', () => {
const deps = {
spacesManager: spacesManagerMock.create(),
notificationsSetup: (notificationServiceMock.create()
notificationsSetup: notificationServiceMock.createSetupContract()
.setup as unknown) as NotificationsSetup,
// we don't have a proper NP mock for this yet
managementSetup: ({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ describe('DeleteSpacesButton', () => {
it('renders as expected', () => {
const spacesManager = spacesManagerMock.create();

const notificatons = (notificationServiceMock.create().start as unknown) as NotificationsStart;
const notifications = notificationServiceMock.createStartContract();

const wrapper = shallowWithIntl(
<DeleteSpacesButton.WrappedComponent
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export const spacesManagementApp = Object.freeze({
http={http}
notifications={notifications}
spacesManager={spacesManager}
securityEnabled={Boolean(securityLicense && securityLicense.getFeatures().showLinks)}
securityEnabled={securityLicense?.getFeatures().showLinks ?? false}
/>
);
};
Expand Down
2 changes: 1 addition & 1 deletion x-pack/plugins/spaces/public/plugin.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ export class SpacesPlugin implements Plugin<SpacesPluginSetup, SpacesPluginStart
management: plugins.management,
getStartServices: core.getStartServices,
spacesManager: this.spacesManager,
securityLicense: plugins.security && plugins.security.license,
securityLicense: plugins.security?.license,
});
}

Expand Down

0 comments on commit 35b81ea

Please sign in to comment.