Donald Trump is a master of controversy-deflection

His $25 million fraud settlement would normally be the headline story throughout the weekend. But instead, Trump made Hamilton Broadway speaking out to Mike Pence at the end of their show the new headline. Something that, aside from the chuckle you get that a gay hating conversion therapy proponent like Mike Pence is spending his evenings taking in broadway shows, is completely devoid of any real substance.

Now Hamilton will be the headline in the newspapers, morning shows, and late night comedy. It’s time we recognize that Donald Trump, or at least the people instructing his social media presence, aren’t the imbeciles we thought they were.

Dear Democrats: if you want to win over white working class voters, here’s 5 things you need to work on

Donald Trump won over white people in 2016. Shocking news I know, but the numbers are quite staggering. He won whites without a college degree by almost 40 points. If the Democrats have any hope of winning the House or Senate in 2018, they need to win over a good portion of these people.

Speaking as a white working class voter in the rust belt and someone that knows a ton of white working class people in the rust belt, I think I have a few points Democrats should be considering going forward.

  1. Blanket labeling the people that voted for Trump as racists or disparaging them for the horrible things Trump says or does will backfire. A lot of these people voted for Barack Obama in 2008 and again in 2012. They voted, in large part, out of fear of their place in the world, their job security, and their future.  They raised a big fat middle finger to what they perceived was wrong with politics by voting for Trump. They’re not bad people and you need their vote.
  2. Stop it with the gun crusade. I get it, you guys don’t like guns, but these people do. And they don’t just like guns, they love guns, guns are a way of life. They are as important to them as a foundational American value as free speech and freedom of the press is to everyone else. Do not give the NRA a reason to throw money at your opposition. And please stop using the made up term assault weapon. It makes you look ignorant and every time you use it a hundred people mail out their next donation to the NRA political fund.
  3. Stop with the political correctness bullshit. People are tired of having to dance on eggshells every time they open their mouths about anything in the political world. A lot of people adore Trump because he “says it like it is” and you have to give him credit for this because it’s true. Embrace that style of speaking to voters. I’m not saying you have to say racist shit, but take off the political correctness filter you apply to everything you say.
  4. Islamic extremism is a problem that needs to be addressed. Recognizing that this is real and people are fearful of it is not islamaphobia, and this goes with point #3. Obviously blanket banning all muslims from entering this country is not a solution, neither is a muslim registry, as Trump is proposing. Recognize this as a legitimate concern of people and come up with a real solution for 2018 and 2020.
  5. You need to have a real conversation about rust belt manufacturing. Trump won a lot of these people over with promises of bringing back manufacturing jobs. It was utter nonsense and his promises aren’t based in any kind of reality. But they bought it, because they’re fearful and some are desperate. They see the writing on the wall and there aren’t any politicians talking to them realistically about this problem. Democrats have ignored them for years and finally Trump came around and promised them the world. You need to have a real talk with these people about globalization, technology, and automation.

Or Don’t, and keep banking on large segments of older white voters dying off. Eventually that might pay off.

I hate JavaScript promises

Well, kinda. I love them in theory I just hate the way they are implemented natively and by libraries like bluebird. Let’s look at this code block for example.

  apiCallOne: (next) => {
    makeApiCall().then((result) => {
      next(null, result.value === true)
  apiCallTwo: (next) => {
    makeApiCallTwo().then((result) => {
      next(null, result.value === true)
  apiCallTheee: (next) => {
}, (err, rv) => {
  throw new Error('wut') // gets swallowed up by the promise chain above

Now, you’re probably asking, why are you mixing promises and callbacks like that? The answer is simple: throughout my code base I’m using async and traditional JavaScript callbacks out of preference but some of the libraries I’m using (like say, Sequelize) utilizes a promise-based API. So I’m forced to mix the two.

You might also be asking what is wrong with the code above. The problem is that all execution down the line after that async execution is now within a promise chain, and that includes error handling. So further on down the line any errors that pop up will be swallowed and silenced because I didn’t specify a .catch() and manually output or handle the error within the makeApiCall promise chain.

This makes my life difficult. I spent at least an hour last night tracking through some code trying to figure out which promise chain was swallowing an error before I finally found it. Stop it promises. Stop swallowing my errors.