Code Monkey home page Code Monkey logo

Comments (8)

nickvergessen avatar nickvergessen commented on May 24, 2024

https://github.com/nextcloud/server/blob/master/lib/public/RichObjectStrings/Definitions.php#L233

Not really, all data is considered to be string, to be on the save side.
You also had it as an int somewhere?

from activity.

MorrisJobke avatar MorrisJobke commented on May 24, 2024

I thought it was. @aleister09 could you check that?

from activity.

aleister09 avatar aleister09 commented on May 24, 2024

Right the id sometimes is int

"subject_rich": [
          "{file} descargado vía enlace público",
          {
            "file": {
              "type": "file",
              "id": 8275,
              "name": "clarobox-090517.apk",
              "path": "APK/clarobox-090517.apk",
              "link": "https://drake.weasel.rocks/f/8275"
            }
          }
        ],

from activity.

nickvergessen avatar nickvergessen commented on May 24, 2024

Well not sure what the problem is? Just cast it to string or int as needed?

from activity.

nickvergessen avatar nickvergessen commented on May 24, 2024

Also I'm not quite sure how this happens, because the value is casted to a string:
https://github.com/nextcloud/server/blob/54e39d4b93b36d38c5f46ef5de4711de48baa0af/apps/files_sharing/lib/Activity/Providers/Base.php#L138-L138

from activity.

aleister09 avatar aleister09 commented on May 24, 2024

@nickvergessen I think it's just happen with public_links
Like this

{
        "activity_id": 2581,
        "app": "files_sharing",
        "type": "public_links",
        "user": "",
        "subject": "alex123.jpg descargado vía enlace público",
        "subject_rich": [
          "{file} descargado vía enlace público",
          {
            "file": {
              "type": "file",
              "id": 8750,
              "name": "alex123.jpg",
              "path": "alex123.jpg",
              "link": "https://drake.weasel.rocks/f/8750"
            }
          }
        ],
        "message": null,
        "message_rich": [
          "",
          []
        ],
        "object_type": "files",
        "object_id": 8750,
        "object_name": "/alex123.jpg",
        "objects": {
          "8750": "/alex123.jpg"
        },
        "link": "",
        "icon": "https://drake.weasel.rocks/core/img/actions/download.svg",
        "datetime": "2017-05-12T16:41:34+00:00"
      }

or this

{
        "activity_id": 2196,
        "app": "files_sharing",
        "type": "public_links",
        "user": "",
        "subject": "APK/clarobox-090517.apk descargado vía enlace público",
        "subject_rich": [
          "{file} descargado vía enlace público",
          {
            "file": {
              "type": "file",
              "id": 8275,
              "name": "clarobox-090517.apk",
              "path": "APK/clarobox-090517.apk",
              "link": "https://drake.weasel.rocks/f/8275"
            }
          }
        ],
        "message": null,
        "message_rich": [
          "",
          []
        ],
        "object_type": "files",
        "object_id": 8275,
        "object_name": "/APK/clarobox-090517.apk",
        "objects": {
          "8275": "/APK/clarobox-090517.apk"
        },
        "link": "",
        "icon": "https://drake.weasel.rocks/core/img/actions/download.svg",
        "datetime": "2017-05-09T20:35:21+00:00"
      }

from activity.

MorrisJobke avatar MorrisJobke commented on May 24, 2024

Well not sure what the problem is? Just cast it to string or int as needed?

It's just an indicator that there is maybe different handling on the server that could cause bugs.

from activity.

nickvergessen avatar nickvergessen commented on May 24, 2024

Well each app has to do this on their own, so yes there is different handling,
if "notifying" was all, I'm going to close this.

from activity.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.