WordPress Ditches “Pee” and “Tinkle” Jokes in Favor of More Inclusive Language and Clearer Code

It feels like the end of an era. Last week, core contributors merged a patch that removed PHP variables named $pee and $tinkle from the WordPress codebase.

Yes, the software that powers 43% of the web has pee-pee jokes in its code.

I know how it sounds. I felt silly writing that sentence.

My job as a writer for WP Tavern affords me the luxury of taking creative license with words every now and again. However, it is a rare treat to write about pee-pee jokes. The chance to do so will not likely come around again. While I could pull out a few doozies from childhood, I promise to remain as professional as possible, given the subject matter.

The vast majority of users are likely unaware of this joke unless they enjoy trawling through the 6,000+ lines of code in /wp-includes/formatting.php. There is a good chance that any developer who has looked up the wpautop() function has stumbled upon it.

Reading through the code can garner a chuckle from a few, but it is a momentary amusement. The problem has always been confusing variable names. In programming, clarity should be favored above all else.

What is a $pee, exactly? It is text. Therefore, $text makes sense as a variable name, which is one of recent code changes. Other modifications include:

  • $pee_parts to $text_parts
  • $last_pee to $last_part
  • $pees to $paragraphs
  • $tinkle to $paragraph

That complex wpautop() function and its 150+ lines of code start making a bit more sense when things are named for clarity.

For the historical record: $pee was first seen in the WordPress codebase in 2003. $tinkle did not make an appearance until five years later.

Developer Rico Moorman asked for the problematic code to be changed in a ticket in 2013. There was some movement to replace the variable names at first. However, after several lead developers stepped in, the idea was shot down. The arguments against the change leaned on keeping the spirit of WordPress, its humor, and its history alive.

However, 2022 is not 2013. The world has changed since the ticket was first opened. While it still has miles to go to be the all-inclusive community it can be, the WordPress space is seemingly more open to checking itself on language issues today.

In 2020, when many in the worldwide developer community switched their default Git repos from “master” to “main,” WordPress followed suit. And, it managed to keep a bit of the charm of its SVN roots by using “trunk” instead.

In 2018, contributors changed text in the Hello Dolly plugin that was degrading to women, especially out of context. The plugin ships with WordPress and randomly displays a single line from Louis Armstrong’s “Hello, Dolly!” in the admin header.

The two offending lines were:

  • “Find her an empty lap, fellas”
  • “Find her a vacant knee, fellas”

Along with some other trivial text changes, the former was removed altogether, and the latter was replaced with “Have a little faith in me, fellas.”

The world changes over time. Language evolves, and what may have been acceptable in years past will not always be so in the future.

Some lead developers may have been OK with the code in 2013. However, the community should never be afraid to reevaluate past stances once in a while. Maybe it was time to ditch the fine art of middle-school jokes in favor of clear and readable code.

Miriam Schwab renewed the discussion via the Post Status Slack chat in December 2021. The general sense from those in the conversation seemed to agree that it was not necessarily offensive but immature. Most of all, it did not have a place in modern WordPress. A team member of Schwab’s had found the code and also renewed the Trac ticket discussion.

During this go-round, there was no pushback. It was simply time to say farewell to a part of the platform’s history.

In this instance, WordPress has not lost any of its personality. Plus ,the variable changes will allow more developers to grasp what is happening in the code.

This does mean that WordPress has a vacancy for at least one new joke or Easter egg. I am still a little salty about losing access to the Matrix. But, it never hurts to mix it up once in a while. WordPress’s in-jokes should continue maturing along with the software.

28

28 responses to “WordPress Ditches “Pee” and “Tinkle” Jokes in Favor of More Inclusive Language and Clearer Code”

  1. Anyone willing to modify the code behind wpautop must be a real whiz. I’d be too afraid of introducing a data leak or something like that. Cheers to the developer! You’d think we could spend a penny and better support some of these volunteers. Relieved it was just a simple change to make things more clear. :)

    • I would argue that it could create an additional barrier to non-native English speakers. The variables were already a problem because they didn’t represent the data itself. Then, you throw in childhood words that may not be readily known to all contributors, it could make it even harder to grok what’s going on.

      In-ticket and elsewhere, others have said they were not comfortable with the terms.

  2. Me and my coworker who came across the code really appreciated how understanding and respectful everyone was about the issue. Yeah, it’s not the end of the world to have code like this, but it can definitely make people uncomfortable, which is unnecessary. My coworker’s perspective was one of fresh eyes since she doesn’t have all the history with WP that I have. She put it really well: she’s in the beginning of her journey with WP and coming across this type of code did not make her feel comfortable or included.

    Thank you to all those involved who respectfully accepted the feedback and quickly implemented the changes! We were all so touched and it was a reminder of how kind and empathetic our community is ❤️

    • “pee” is the name/spelling of the letter P in English. More than one pee is “pees”. Since this function wraps text in one or more HTML p tags, the variable name(s) (pee and pees) referenced the text that needed to be split up and wrapped in p tags.

      Really, it’s the word “tinkle” that was the joke, and probably this could have been resolved by just removing that word. Without that, every reference of “pee” is above board, unless someone chooses to interpret it as urine. For posterity, the use of “tinkle” in the context of the code was referencing a part of multiple pees after being split.

  3. The only good reason to change this is that it’s not very clear what the variable means exactly. Children who speak French are always embarrassed when they meet the term “bit” as it’s very (very) close to a word designating the sexual male organ. So, what is the best here : speaking French people should find another term than “bit” ? Or the entire developers community should change the term “bit” so French speaking women won’t be embarrassed ?

      • Yes. Cockney is a real thing. It is the dialect of British English as spoken by a real Cockney person.
        So what then is wp_cockneyreplace? Some kind of final solution for East end Londoners? And people consider that $pee is non-inclusive.
        I looked at what the function does, thinking purely of the language aspect – and reflecting that it must be pretty clever to replace, say, plates by feet. That would be dealing with Cockney.
        But no, it doesn’t.
        What it’s actually doing is dealing with contractions and more specifically contractions with a leading apostrophe.
        wp_contractionsreplace would describe what it does.

        • I’ve spent a lot of my time already looking at exclusive language and I’m not sure where this falls into the category. It’s not being insulting to Cockney people (my own grandmother was Cockney), but rather tying this to dealing with contractions, in a similar method of Cockney Rhyming Slang.

          Having said all that, it’s a bit of a stretch to relate the two together and, as a lot of people simply won’t understand the reference, it would probably be better if it was named something more obvious. However, I’d see this is pretty low on the urgency list.

  4. I am not the most politically correct person but I don’t offend.

    How does a bodily function that almost 8 billion people do 1-3 times a day make people not be included?

    There are a million ways to say #1 and #2. I grew up with #1 and #2. Now repeat that in every other languages.

    #1 is front, #2 is in the back. In case any of you are wondering.

    Just mentioning Pee is not bad language. If you are saying someone who has to sit to pee instead of standing up is wrong and can’t help with WordPress…or the other way around……then yes, that could be non-inclusive.

    Though, English is not my first language and I have lived in Canada for 30-ish years…I never used tinkle. I said pee.

    What is next…poop? burping? farting? Apparently some people say belching. I use burping. I honestly do not the difference.

    What if I create a plugin that shows a daily photo of my yellow snow drawings. It is easier for some people than others to do that.

    Having $pee on the code does not prevent you or anyone else from participating.

    I personally don’t care what you call bodily functions, call them whatever you want.

    I would sort of understand if someone came with a MAGA hat to a WordCamp and you are not a Trump supporter.

    I would understand if you are at a WordCamp event and someone comes wearing a hat or/and t-shirt with a nazi symbol or any other racist symbol.

    However, $pee, I would giggle at it and if I would of founded…I would of tweeted about it.

    it isn’t like there is $(racist-word-or-symbol-here).

    It is just $pee

    Please be aware that I am entitled to an opinion, you are also entitled to no agree with my opinion. However you do not have the right to “cancel” me, like I have no right to “cancel” you because you disagreed with me.

    • When the discussion came up in the Post Status slack, I was the person who asked for the ticket to be reopened to be committed during the WordPress 6.0 cycle.

      To me, it was a no-brainier and nothing to do with political correctness: some badly named variables based on an in-joke upset someone. With a few minutes work the purpose of the variables would become clearer and no one would be upset.

      I see no difference between this commit and an earlier one I made to remove an in-joke from a comment and replace it with something clearer. I guess the earlier commit wasn’t worth a discussion because the joke didn’t relate to bodily functions.

    • I do agree with you, and keeping little touches throughout the project is important to me. This isn’t one of those little touches that I really care about though. It’s kind of irrelevant to modern WordPress. The autop code will always be with us, but it’s largely a relic, so preserving it doesn’t matter that much. IMO.

  5. Ahh, I remember when it was mentioned here that I’d been working on some changes to exclusive language within WordPress (blacklist to blocklist – remember that?). I’ve learnt that not everybody appreciates these kinds of changes, however well-meaning. But I do applaud what’s been done here. I’m sure these aren’t the last changes we’ll see of this type (those comments in the WordPress code are ripe for improvement!)


You may also like

Newsletter

Subscribe Via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.