mattermost / mattermost/mattermost-plugin-cloud
Webapp console error ` t.map is not a function`
Open
Nobody has claimed this yet.
Type/Bug
- Dominant language
- Go
- Stars
- 11
- Forks
- 11
- PR merge metrics
- No merged PRs in 30d
Description
An error occurs with the Cloud plugin sometimes on community when opening a profile popover. Here is the minified code snippet that's causing the issue:
var T, S, w, R = r(7363), O = r.n(R), A = r(7086), N = r.n(A);
class k extends O().PureComponent {
componentDidMount() {
this.props.actions.getCloudUserData(this.props.id)
}
render() {
const t = this.props.installs;
if (0 === t.length)
return null;
const e = t.map((t=>O().createElement("li", { // Error is happening right here
key: t.ID
}, O().createElement("a", {
href: "https://" + t.DNS,
target: "_blank",
rel: "noopener noreferrer"
}, t.Name))));
return O().createElement("div", {
style: C.container
}, O().createElement("div", null, "Cloud Servers"), O().createElement("ul", null, e))
}
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the React component that renders the Cloud Servers list and tracing the getCloudUserData response used as this.props.installs. Reproduce the profile popover error on community, then verify that opening it produces no console error and that the installs list renders when data is returned.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, react
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100