View Issue Details

IDProjectCategoryView StatusLast Update
0000688XMB1Bugspublic2024-04-15 04:35
Reporterflushedpancake Assigned Tomiqrogroove  
PrioritynormalSeverityminorReproducibilitysometimes
Status closedResolutionfixed 
Product Version1.9.12.05 
Target Version1.9.12.06Fixed in Version1.9.12.06 
Summary0000688: When a person with a non-default rank posts, every poster after them with a default rank on the same page displays it, too
DescriptionThis is likely due to an uninitialised variable somewhere, judging from what it looks like.

e.g. if an admin posts, and 2 normal users reply, then the two people who replied will both display as administrators on their posts' sidebars for that page. If a moderator, and then a super admin replies, they will both show as their respective ranks, but then if a normal user replies they will be shown as a super admin.
Steps To Reproducehttps://forums.xmbforum2.com/viewthread.php?tid=777048

This thread in particular seems to show this bug quite well, but any thread with an ordinary user posting and a staff member will work.

Additional InformationI have not tested this on localhost, so cannot be sure if it's just a bug on the devboard.
TagsNo tags attached.
MySQL Version
PHP Version
Web Server
Browser
Flags
Original Reporter
SVN Revision3035

Relationships

related to 0000677 closedmiqrogroove Refactor Unreadable Member Rank Code in viewthread.php 

Activities

flushedpancake

2024-04-03 12:39

reporter  

miqrogroove

2024-04-03 13:49

administrator   ~0000447

Nice catch.

flushedpancake

2024-04-07 00:58

reporter   ~0000453

Last edited: 2024-04-09 14:11

Yep, when all post based ranks are removed, this happens

Warning: Trying to access array offset on value of type null in /var/www/html/viewthread.php on line 642

Deprecated: str_repeat(): Passing null to parameter 2 ($times) of type int is deprecated in /var/www/html/viewthread.php on line 643

Warning: Trying to access array offset on value of type null in /var/www/html/viewthread.php on line 644

I guess hardcoding a fallback value if no post based ranks are set would work

miqrogroove

2024-04-07 21:09

administrator   ~0000454

Last edited: 2024-04-09 14:13

If that's a separate bug then please open a separate bug here.

The variable in question for the first bug is likely $rank. It is initialized but sometimes it gets set to a PHP reference. In that case the problem is that the reference needs to be unset before it gets reused in the outer loop.

flushedpancake

2024-04-08 19:30

reporter   ~0000456

Can you update the reproducibility to 'always'? I don't think I'm capable of doing it.

miqrogroove

2024-04-09 13:57

administrator   ~0000459

Bug behavior is more complex than described. Should be a simple fix though.

miqrogroove

2024-04-10 04:34

administrator   ~0000473

Comment 453 copied to issue 0000701

Issue History

Date Modified Username Field Change
2024-04-03 12:39 flushedpancake New Issue
2024-04-03 12:39 flushedpancake File Added: F5115BED-063F-4F7F-A4C3-C7A4BF2AD961.png
2024-04-03 12:39 flushedpancake File Added: C6D8472C-5320-4DE6-AFFF-3DF41F92E94B.png
2024-04-03 12:39 flushedpancake File Added: 94370C41-6333-45F3-872A-1F5B5C2479C8.png
2024-04-03 12:39 flushedpancake File Added: 8AE1B9EF-5B3E-41DC-9285-35B549163088.png
2024-04-03 13:49 miqrogroove Assigned To => miqrogroove
2024-04-03 13:49 miqrogroove Status new => acknowledged
2024-04-03 13:49 miqrogroove Note Added: 0000447
2024-04-07 00:58 flushedpancake Note Added: 0000453
2024-04-07 00:58 flushedpancake File Added: Screenshot_2024-04-07_08-55-22.png
2024-04-07 21:09 miqrogroove Note Added: 0000454
2024-04-08 19:30 flushedpancake Note Added: 0000456
2024-04-09 13:55 miqrogroove Relationship added related to 0000677
2024-04-09 13:57 miqrogroove Reproducibility have not tried => sometimes
2024-04-09 13:57 miqrogroove Status acknowledged => assigned
2024-04-09 13:57 miqrogroove Target Version => 1.9.12.06
2024-04-09 13:57 miqrogroove Note Added: 0000459
2024-04-09 14:10 miqrogroove Status assigned => resolved
2024-04-09 14:10 miqrogroove Resolution open => fixed
2024-04-09 14:10 miqrogroove Fixed in Version => 1.9.12.06
2024-04-09 14:10 miqrogroove SVN Revision => 3035
2024-04-09 14:11 miqrogroove Note Edited: 0000453
2024-04-09 14:13 miqrogroove Note Edited: 0000454
2024-04-09 14:13 miqrogroove Note Edited: 0000454
2024-04-10 04:34 miqrogroove Note Added: 0000473
2024-04-15 04:35 miqrogroove Status resolved => closed