Skip to content

Commit

Permalink
chore: remove deprecated plugin wrapper (#25)
Browse files Browse the repository at this point in the history
### What this PR does?
移除对已过时的 PluginWrapper 的引用,Halo 2.18.0 版本后将不在支持从 BasePlugin 中获取 PluginWrapper ,也不再支持依赖注入 PluginWrapper,使用 PluginContext 代替

see also halo-dev/halo#6243 for more details

```release-note
None
```
  • Loading branch information
ruibaby authored Jul 4, 2024
1 parent 1fda9c3 commit d90548c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
6 changes: 5 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,11 @@ plugins {
}

group 'run.halo.umami'
sourceCompatibility = JavaVersion.VERSION_17

java {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}

repositories {
maven { url 'https://s01.oss.sonatype.org/content/repositories/snapshots' }
Expand Down
7 changes: 4 additions & 3 deletions src/main/java/run/halo/umami/UmamiPlugin.java
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
package run.halo.umami;

import org.pf4j.PluginWrapper;
import org.springframework.stereotype.Component;

import run.halo.app.plugin.BasePlugin;
import run.halo.app.plugin.PluginContext;

/**
* @author guqing
Expand All @@ -11,8 +12,8 @@
@Component
public class UmamiPlugin extends BasePlugin {

public UmamiPlugin(PluginWrapper wrapper) {
super(wrapper);
public UmamiPlugin(PluginContext context) {
super(context);
}

@Override
Expand Down

0 comments on commit d90548c

Please sign in to comment.