opencode-auto-resume 1.0.9 → 1.0.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +7 -1
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -220,8 +220,14 @@ var AutoResumePlugin = async (ctx, options) => {
220
220
  const role = msg.role ?? msg.info?.role;
221
221
  if (role === "user") {
222
222
  const rawAgent = msg.agent;
223
- if (typeof rawAgent === "string")
223
+ if (typeof rawAgent === "string") {
224
224
  agent2 = rawAgent;
225
+ } else {
226
+ const fallbackAgent = msg.info?.agent;
227
+ if (typeof fallbackAgent === "string") {
228
+ agent2 = fallbackAgent;
229
+ }
230
+ }
225
231
  let rawModel = msg.model;
226
232
  if (!rawModel) {
227
233
  rawModel = msg.info?.model;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "opencode-auto-resume",
3
- "version": "1.0.9",
3
+ "version": "1.0.10",
4
4
  "description": "OpenCode plugin that automatically resumes stalled LLM sessions when thinking/streaming freezes mid-generation.",
5
5
  "keywords": [
6
6
  "opencode",