]> cat aescling's git repositories - mastodon.git/commitdiff
Fix non-numeric account identifiers leading to /web/accounts/NaN
authorThibaut Girka <thib@sitedethib.com>
Thu, 21 Feb 2019 20:13:12 +0000 (21:13 +0100)
committerThibG <thib@sitedethib.com>
Fri, 22 Feb 2019 16:52:21 +0000 (17:52 +0100)
I'm not sure what purpose these “+” served?!

app/javascript/flavours/glitch/components/status_header.js
app/javascript/flavours/glitch/components/status_prepend.js

index 65458e3f03c4b6c9853104a35bc2baba2f856bfe..f9321904ca0e7fc51ed80811fcaaf4577fd39302 100644 (file)
@@ -19,7 +19,7 @@ export default class StatusHeader extends React.PureComponent {
   //  Handles clicks on account name/image
   handleAccountClick = (e) => {
     const { status, parseClick } = this.props;
-    parseClick(e, `/accounts/${+status.getIn(['account', 'id'])}`);
+    parseClick(e, `/accounts/${status.getIn(['account', 'id'])}`);
   }
 
   //  Rendering.
index f4ef83135f0fc7d8ed74bc07a26cad95f0918add..4e329f546ee492bda6b4ffcc95ef83fff9709161 100644 (file)
@@ -15,7 +15,7 @@ export default class StatusPrepend extends React.PureComponent {
 
   handleClick = (e) => {
     const { account, parseClick } = this.props;
-    parseClick(e, `/accounts/${+account.get('id')}`);
+    parseClick(e, `/accounts/${account.get('id')}`);
   }
 
   Message = () => {