[ https://issues.apache.org/jira/browse/CB-6703?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13999822#comment-13999822 ]
Ian Clelland commented on CB-6703: ---------------------------------- Looks like the last JS interface to this was removed in CB-229 (cordova-android:3628410); even before the PhoneGap->Cordova transition. I think we could safely remove the code here. It might also be possible to make a standardized interface, given the deprecation of the W3 spec, but I don't know if just attaching a JS function to *this* native code is the right way to do it. Different parts of the filesystem can have different amounts of space available -- especially on Android, where an attached SD card is a different writable space than the internal flash RAM. A {{getFreeDiskSpace}} method, scoped to the {{fileSystem}} object, might be more useful. Also, we already have a "size" parameter on the {{requestFileSystem}} API call -- we should be respecting that, and failing if the requested space isn't available. Another way to do this, if the goal is just to ensure that the device has sufficient space, and to fail gracefully if not, would be to use the {{requestQuota}} interface that Chrome implements (https://groups.google.com/a/chromium.org/d/msg/chromium-html5/m-ei3ATZr2c/ZkO6ZkLSYVIJ). With that, that the app can request as much space as it actually wants, and the plugin will respond with the amount of space that it can have. > getFreeDiskSpace() unused, not in the .js interface > --------------------------------------------------- > > Key: CB-6703 > URL: https://issues.apache.org/jira/browse/CB-6703 > Project: Apache Cordova > Issue Type: Bug > Components: Plugin File > Reporter: Shazron Abdullah > > This is because it's not part of the w3c spec. > Remove? > Consequently I was made aware of this because of a PR: > https://github.com/apache/cordova-plugin-file/pull/45 -- This message was sent by Atlassian JIRA (v6.2#6252)