Breaking this off from #1191236: Correct file_copy, file_move, file_save_data, and drupal_realpath to match documentation and their unmanaged counterparts.

The documentation for the $uri parameter to drupal_realpath() says, in part:

If this value is omitted, Drupal's default files directory will be used [public://].

However, this claim is untrue. Omitting the $uri parameter will actually result in a PHP warning, and the function will return FALSE.

Comments

pillarsdotnet’s picture

Status: Active » Needs review
StatusFileSize
new1.03 KB

Patch makes the code match the docs.

pillarsdotnet’s picture

Title: Make the code of drupal_realpath() match the docs. » Make code of drupal_realpath() match docs.
Issue tags: +Needs backport to D7
pillarsdotnet’s picture

Issue tags: +API clean-up
pillarsdotnet’s picture

Status: Needs review » Closed (duplicate)