title: Remove file name from path in Automator
body: <p>I'm creating an automator service that will mark my invoices as paid... I've got a workflow that gets selected PDF, sets variable to path of PDF, Watermarks it, then returns it to it's original location. However the final step doesn't work as the path variable links to the PDF rather than a folder.</p>
  
  <p>Please help.</p>
  
  <p><img src="https://i.stack.imgur.com/z2nLM.png" alt="workflow"></p>