Skip to content
This repository has been archived by the owner on Apr 12, 2024. It is now read-only.

Problem with angular 1.0.4 #1963

Closed
alexbardas opened this issue Feb 6, 2013 · 4 comments
Closed

Problem with angular 1.0.4 #1963

alexbardas opened this issue Feb 6, 2013 · 4 comments

Comments

@alexbardas
Copy link

My app broke after the upgrade to 1.0.4 version. After debugging, I noticed that it's missing some code. For example, if you search in 1.0.4 after (isDefined(template = next.template)) you'll notice that

if (isFunction(template)) {
     template = template(next.params);
}

is missing. Same thing happens in the next statement. On master branch everything seems ok master.

I'm running a patched version now, but what happened to the build version?

@pkozlowski-opensource
Copy link
Member

@alexbardas your are looking at the build of 1.0.4 so you should be checking corresponding sources:
https://github.com/angular/angular.js/blob/v1.0.4/src/ng/route.js

As you can see there is nothing wrong with the build so I've renamed the issue.

Now, if you see the blame command for the file in question: https://github.com/angular/angular.js/blame/v1.0.4/src/ng/route.js

you will notice that the lines in question weren't changed for over 6 months so so the code was like this in previous AngularJS releases.

I understand that you are facing the issue but you will have to provide more info:

  • what exactly is breaking in your application
  • reproduce scenario
  • from which version of AngularJS have you switched to 1.0.4?

@alexbardas
Copy link
Author

Thanks for the response. I included a plnkr which illustrates the problem.

First of all, I already had a patched 1.0.3 version, so this is why it worked fine, just that I forgot about it.

I decided to upgrade to official 1.0.4 (from bower) and the app broke. The plunkr example is just a dummy use case about how the app breaks. In index.html, I load my patched version (same as 1.0.3 but has isFunction(..) from the first comment ). If you switch to google cdn version, you will see that the app breaks when you click on the last 2 links from the plnkr example.

LE:

I saw now that the patched was based on this issue #1524. This issue was merged into master before the last build, so I thought the build would have the patch.

@pkozlowski-opensource
Copy link
Member

I guess you problem is with functions being used as templateUrl which is not supported in 1.0.4. Support for functions as templateUrl landed in 1.1.2: https://github.com/angular/angular.js/blob/master/CHANGELOG.md#features in this commit:
faf02f0

Please check if 1.1.2 works for you.

@alexbardas
Copy link
Author

Ok, 10x a lot. I'll close this.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants