UNPKG

@lynsoluciones/medusa-docs

Version:
30 lines (29 loc) 842 B
"use strict"; /* * * * MIT License * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ Object.defineProperty(exports, "__esModule", { value: true }); exports.GET = void 0; const GET = async (req, res) => { const invoiceService = req.scope.resolve('invoiceService'); try { const documentSettings = await invoiceService.getDocumentSettings(); res.status(200).json({ settings: documentSettings }); } catch (e) { res.status(400).json({ message: e.message }); } }; exports.GET = GET;