Skip to content

Commit

Permalink
Merge branch '2.4.x' into 2.5.x
Browse files Browse the repository at this point in the history
Closes gh-27419
  • Loading branch information
wilkinsona committed Jul 20, 2021
2 parents c2819d6 + b5587b0 commit a5e95ef
Showing 1 changed file with 2 additions and 2 deletions.
@@ -1,5 +1,5 @@
/*
* Copyright 2012-2019 the original author or authors.
* Copyright 2012-2021 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -43,7 +43,7 @@ public String[] getFileExtensions() {

@Override
public List<PropertySource<?>> load(String name, Resource resource) throws IOException {
if (!ClassUtils.isPresent("org.yaml.snakeyaml.Yaml", null)) {
if (!ClassUtils.isPresent("org.yaml.snakeyaml.Yaml", getClass().getClassLoader())) {
throw new IllegalStateException(
"Attempted to load " + name + " but snakeyaml was not found on the classpath");
}
Expand Down

0 comments on commit a5e95ef

Please sign in to comment.