diff --git a/zebedee-cms/src/main/java/com/github/onsdigital/zebedee/ZebedeeConfiguration.java b/zebedee-cms/src/main/java/com/github/onsdigital/zebedee/ZebedeeConfiguration.java index b0f502a87..7a1a07899 100644 --- a/zebedee-cms/src/main/java/com/github/onsdigital/zebedee/ZebedeeConfiguration.java +++ b/zebedee-cms/src/main/java/com/github/onsdigital/zebedee/ZebedeeConfiguration.java @@ -43,7 +43,6 @@ import com.github.onsdigital.zebedee.servicetokens.store.ServiceStoreImpl; import com.github.onsdigital.zebedee.session.service.JWTSessionsServiceImpl; import com.github.onsdigital.zebedee.session.service.Sessions; -import com.github.onsdigital.zebedee.session.service.SessionsServiceImpl; import com.github.onsdigital.zebedee.session.service.ThreadLocalSessionsServiceImpl; import com.github.onsdigital.zebedee.session.store.SessionsStore; import com.github.onsdigital.zebedee.session.store.SessionsStoreImpl; @@ -92,7 +91,7 @@ import static com.github.onsdigital.zebedee.configuration.Configuration.getSlackToken; import static com.github.onsdigital.zebedee.configuration.Configuration.isVerificationEnabled; import static com.github.onsdigital.zebedee.configuration.Configuration.slackChannelsToNotfiyOnStartUp; -import static com.github.onsdigital.zebedee.permissions.store.PermissionsStoreFileSystemImpl.initialisePermissions; +import static com.github.onsdigital.zebedee.permissions.store.PermissionsStoreFileSystemImpl.initialiseAccessMapping; import static org.apache.commons.lang3.StringUtils.isEmpty; /** @@ -312,7 +311,7 @@ private void initTeamsService(Path zebedeePath, */ private void initPermissionsService(Path zebedeePath, TeamsService teamsService) throws IOException { Path permissionsPath = createDir(zebedeePath, PERMISSIONS); - initialisePermissions(permissionsPath); + initialiseAccessMapping(permissionsPath); PermissionsStore permissionsStore = new PermissionsStoreFileSystemImpl(permissionsPath); PermissionsServiceImpl legacyPermissionsService = new PermissionsServiceImpl(permissionsStore, this::getTeamsService); diff --git a/zebedee-cms/src/main/java/com/github/onsdigital/zebedee/permissions/store/PermissionsStoreFileSystemImpl.java b/zebedee-cms/src/main/java/com/github/onsdigital/zebedee/permissions/store/PermissionsStoreFileSystemImpl.java index ba5474a2a..5a2c04a19 100644 --- a/zebedee-cms/src/main/java/com/github/onsdigital/zebedee/permissions/store/PermissionsStoreFileSystemImpl.java +++ b/zebedee-cms/src/main/java/com/github/onsdigital/zebedee/permissions/store/PermissionsStoreFileSystemImpl.java @@ -38,7 +38,7 @@ public class PermissionsStoreFileSystemImpl implements PermissionsStore { * @param accessMappingPath the path of the accessMapping json file. * @throws IOException error while initializing. */ - public static void initialisePermissions(Path accessMappingPath) throws IOException { + public static void initialiseAccessMapping(Path accessMappingPath) throws IOException { Path jsonPath = accessMappingPath.resolve(PERMISSIONS_FILE); if (!Files.exists(jsonPath)) { diff --git a/zebedee-cms/src/test/java/com/github/onsdigital/zebedee/permissions/store/PermissionsStoreFileSystemImplTest.java b/zebedee-cms/src/test/java/com/github/onsdigital/zebedee/permissions/store/PermissionsStoreFileSystemImplTest.java index af74ea94e..9b5239e94 100644 --- a/zebedee-cms/src/test/java/com/github/onsdigital/zebedee/permissions/store/PermissionsStoreFileSystemImplTest.java +++ b/zebedee-cms/src/test/java/com/github/onsdigital/zebedee/permissions/store/PermissionsStoreFileSystemImplTest.java @@ -46,7 +46,7 @@ public void tearDown() throws Exception { @Test public void constructor_ShouldCreateAccessMappingIfDoesNotExist() throws Exception { - PermissionsStoreFileSystemImpl.initialisePermissions(permissionsDir); + PermissionsStoreFileSystemImpl.initialiseAccessMapping(permissionsDir); PermissionsStore store = new PermissionsStoreFileSystemImpl(permissionsDir); assertThat(Files.exists(accessMappingPath.toPath()), is(true));