Imagine you schedule a dream vacation to Venice. Now imagine, after the trip is all booked, you discover that your company's CEO will be visiting your office while you're set to be away. How big a disaster are you facing?

That depends on a bunch of factors, but one of the biggest is who exactly your CEO is and what his or her attitudes are towards "face time" and flexibility.

Thankfully, for Dublin-based LinkedIn analytics manager Mariah Walton, she had the good fortune of having Jeffrey Weiner as a CEO when she faced just this conundrum. Together Walton and her CEO turned what could have been a missed opportunity (or job-ending faux pas) into a masterclass is great leadership.

A picture is worth a thousand words

Walton was determined not to miss her Italian getaway, but she was equally set on making an impression on the big boss, so what did she do? Thinking on her feet, she tacked a picture of herself to her computer and left Weiner a note expressing her regret that she missed the opportunity to chat with him about her role and grab a selfie with the CEO.

Weiner, noticed the note and, obviously nonplussed that his employee was away on holiday, sent her a snap of himself at her desk. Walton shared the moment on LinkedIn. It's since gone viral with more than 30,000 likes and nearly 500 comments:

Mariah Walton on LinkedIn: "When you accidentally schedule your...

When you accidentally schedule your vacation for the day your CEO is specifically dropping by to meet your team, it doesn't hurt to 'subtly' remind t...

Why this picture is so powerful

Why did the post get such a strong reaction? Possibly because of the conversation it sparked between those who thought an absence like Walton's would be career suicide at their company - "If you would of worked in my country, you would of get fired," said one commenter; "Sounds like one less name on Jeff's Holiday Card list to me," taunted another - and those applauding a CEO for recognizing the value of time away to unplug and recharge.

Luckily for Walton, Weiner is clearly in the camp of those who have read the research that shows de-emphasizing "face time" and allowing flexibility not only makes workers more productive, it also makes them more motivated.

"Mariah, sorry I missed you this trip to Dublin. Keep up the great work on the international dashboard. Has been a game changer for the product team," Weiner wrote in reply to Walton's post.

His willingness to see his employee as a human being and respond with empathy and humor is winning him more hard work and dedication than dour-faced whip cracking ever would. "I've always found the most effective teams are highly self motivated, which is hard to inspire in heavily hierarchical environments," Walton replied to one of the more skeptical responses to her post.

By connecting with his team on a personal level and acknowledging their lives as humans who enjoy canals and pizza as well as work and CEO handshakes, Weiner inspired just that sort of performance-boosting intrinsic motivation. Maybe that's part of what's "helped earn Weiner the #35 slot on Glassdoor's 2017 list of the highest-rated CEOs in the world, ahead of contemporaries like Uber CEO Dara Khosrowshahi (#39), Twitter/Square CEO Jack Dorsey (#38), and Apple CEO Tim Cook (#53)," notes Business insider's write-up of the incident.

The lesson for other business leaders is pretty clear: there's huge value in not just saying you support work-life balance and flexibility in your employee manual or company values, but in actually acting like that's true. And bonus points to you if you can convey that message with a little humor and a human touch.