Closed Bug 994651 Opened 6 years ago Closed 6 years ago

TypeError: anonymous function does not always return a value @ osfile_shared_front.jsm:551

Categories

(Toolkit :: OS.File, defect, trivial)

x86
macOS
defect
Not set
trivial

Tracking

()

RESOLVED FIXED
mozilla32

People

(Reporter: florian, Assigned: shashank)

References

Details

(Whiteboard: [mentor=Yoric][lang=js][good first bug])

Attachments

(1 file)

Saw this warning a few times in my Browser Console:
TypeError: anonymous function does not always return a value osfile_shared_front.jsm:551

This points to:
551 AbstractFile.makeDir = function(path, options = {}) {
552   if (!options.from) {
553     return OS.File._makeDir(path, options);
554   }

http://mxr.mozilla.org/mozilla-central/source/toolkit/components/osfile/modules/osfile_shared_front.jsm#551

If the function isn't intended to return a value, this is all is needed to silence the warning:
  if (!options.from) {
    OS.File._makeDir(path, options);
    return;
  }
Whiteboard: [mentor=Yoric][lang=js]
Whiteboard: [mentor=Yoric][lang=js] → [mentor=Yoric][lang=js][good first bug]
Attached patch BUG994651.patchSplinter Review
BUG 994651: Split the statement with 'return' into two parts
Attachment #8427802 - Flags: review?(dteller)
Flags: needinfo?(dteller)
Comment on attachment 8427802 [details] [diff] [review]
BUG994651.patch

Review of attachment 8427802 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good, thanks.
Can you push to try or do you need me to?
Attachment #8427802 - Flags: review?(dteller) → review+
Duplicate of this bug: 1015124
(In reply to David Rajchenbach Teller [:Yoric] (please use "needinfo?" - I'll be away on May 16th-23th) from comment #2)
> Review of attachment 8427802 [details] [diff] [review]:
> -----------------------------------------------------------------
> 
> Looks good, thanks.
> Can you push to try or do you need me to?

Thanks for the review.
I'm in the process of applying for Level 1 access (which I assume is needed to gain push access).

I request you to push this to try yourself as I am unaware of the time it takes for me gaining access.

Thanks,
Shashank
Try results will show up here: https://tbpl.mozilla.org/?tree=Try&rev=13326428b76e
Flags: needinfo?(dteller)
Try looks good. Ready to land this when you are, Shashank.
Assignee: nobody → shashank
Flags: needinfo?(shashank)
Dear Yoric,

I'm sorry that I don't understand what we're waiting for. Please let me know if I'm expected to do anything more.

Also, I applied for 'TRY access' here:
https://bugzilla.mozilla.org/show_bug.cgi?id=1016704

Could you please vouch for me there?

Thanks,
Shashank VRSN Sabniveesu
(shashank@linux.com)
Flags: needinfo?(shashank) → needinfo?(dteller)
I'm asking whether you are ready or whether you want to change anything before we land this patch into mozilla-central.
Flags: needinfo?(dteller) → needinfo?(shashank)
Nothing else. Please go ahead with landing.
Flags: needinfo?(shashank) → needinfo?(dteller)
Flags: needinfo?(dteller)
Keywords: checkin-needed
https://hg.mozilla.org/integration/fx-team/rev/ac5da67a0be2
Keywords: checkin-needed
Whiteboard: [mentor=Yoric][lang=js][good first bug] → [mentor=Yoric][lang=js][good first bug][fixed-in-fx-team]
Hi!

May I know what this 'fixed-in-fx-team' clause means? Why is it specifically mentioned? I haven't seen this tag for any other bugs I submitted patches to.

Thanks,
Shashank
Flags: needinfo?(ryanvm)
fx-team is another staging branch like mozilla-inbound. It'll merge to m-c from there and this bug will be resolved once it is.
Flags: needinfo?(ryanvm)
https://hg.mozilla.org/mozilla-central/rev/ac5da67a0be2
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Whiteboard: [mentor=Yoric][lang=js][good first bug][fixed-in-fx-team] → [mentor=Yoric][lang=js][good first bug]
Target Milestone: --- → mozilla32
You need to log in before you can comment on or make changes to this bug.