pull/1401/head
Ryan Wang 2021-06-11 23:45:37 +08:00 committed by GitHub
parent 9de40a0a1c
commit e72fe2179a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 16 deletions

View File

@ -295,21 +295,7 @@ public class InstallController {
properties.put(BlogProperties.BLOG_URL,
StringUtils.isBlank(installParam.getUrl()) ? optionService.getBlogBaseUrl() :
installParam.getUrl());
Long birthday =
optionService.getByPropertyOrDefault(PrimaryProperties.BIRTHDAY, Long.class, 0L);
if (birthday.equals(0L)) {
properties.put(PrimaryProperties.BIRTHDAY, String.valueOf(System.currentTimeMillis()));
}
Boolean globalAbsolutePathEnabled = optionService
.getByPropertyOrDefault(OtherProperties.GLOBAL_ABSOLUTE_PATH_ENABLED, Boolean.class,
null);
if (globalAbsolutePathEnabled == null) {
properties.put(OtherProperties.GLOBAL_ABSOLUTE_PATH_ENABLED, Boolean.FALSE.toString());
}
properties.put(OtherProperties.GLOBAL_ABSOLUTE_PATH_ENABLED, Boolean.FALSE.toString());
// Create properties
optionService.saveProperties(properties);

View File

@ -33,7 +33,7 @@ class IndexPageRequestTest extends BaseApiTest {
// validate post link
Element postTitleLink =
document.body().selectFirst(".content > .post > .post-title > h3 > a");
assertEquals(blogUrl + "/archives/hello-halo", postTitleLink.attr("href"));
assertEquals("/archives/hello-halo", postTitleLink.attr("href"));
assertEquals("Hello Halo", postTitleLink.text());
}
}