Skip to content

padUpdate missing padId  #5814

@danielpetri1

Description

@danielpetri1

Describe the bug
The padUpdate hook does not appear to include the pad.id attribute as it did in 1.8.17.

Sample:

{
    "body": {
        "pad": {
            "atext": {
                "text": "​s\n",
                "attribs": "+1*0+1|1+1"
            },
            "pool": {
                "numToAttrib": {
                    "0": [
                        "author",
                        "a.i2WSCwOkL5ZS19pD"
                    ]
                },
                "nextNum": 1
            },
            "head": 1,
            "chatHead": -1,
            "publicStatus": false,
            "savedRevisions": []
        },
        "authorId": "a.i2WSCwOkL5ZS19pD",
        "author": "a.i2WSCwOkL5ZS19pD",
        "revs": 1,
        "changeset": "Z:2>1=1*0+1$s"
    }
}

Expected behavior
The hook should provide the padId in the pad object so that it is possible to know which pad was modified.

Server (please complete the following information):

  • Etherpad version: 1.9.1
  • OS: Ubuntu 20.04
  • Node.js version (node --version): v16.20.0
  • npm version (npm --version): 8.19.4

Additional context
Pad was created via the HTTP API. It may be related to the open issues/PR surrounding the appendRevision method. I tried the suggested fix but it did not resolve this issue.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions