Document.get_absolute_url() providing different result at different times

RESOLVED INVALID

Status

Mozilla Developer Network
General
RESOLVED INVALID
4 years ago
4 years ago

People

(Reporter: davidwalsh, Unassigned)

Tracking

Details

(Whiteboard: [specification][type:change])

(Reporter)

Description

4 years ago
What feature should be changed? Please provide the URL of the feature if possible.
==================================================================================
It appears the get_absolute_url() method of the Document model is returning different results within the model and on individual instances.

With Document's build_json_data method, get_absolute_url() does not account for the zone alias.  Calling the method outside of the model returns the aliased URL.

What problems would this solve?
===============================
Writers use the URL lookup (via the autosuggest_documents view) to get subnav URLs.  We should serve the aliased URL.

Who would use this?
===================
Eryone.

What would users see?
=====================
The aliased URL in subnav, etc.

What would users do? What would happen as a result?
===================================================
N/A

Is there anything else we should know?
======================================
Les Orchard is smarter than me.
(Reporter)

Comment 1

4 years ago
Need to edit and commit the aliased page before JSON data returns the correct URL. :/  Probably invalid.
Status: NEW → RESOLVED
Last Resolved: 4 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.