refactor Go functions to GoFunc names
This commit is contained in:
parent
c5503ef282
commit
dbba2171db
@ -1,7 +1,7 @@
|
|||||||
import { Component, OnInit } from '@angular/core';
|
import { Component, OnInit } from '@angular/core';
|
||||||
import { Title } from '@angular/platform-browser';
|
import { Title } from '@angular/platform-browser';
|
||||||
import { Game } from 'src/app/interfaces/game.interface';
|
import { Game } from 'src/app/interfaces/game.interface';
|
||||||
import { GetGames } from 'src/app/services/go';
|
import { GoGetGames } from 'src/app/services/go';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-games-bar',
|
selector: 'app-games-bar',
|
||||||
@ -19,7 +19,7 @@ export class GamesBarComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
|
|
||||||
getGames() {
|
getGames() {
|
||||||
if (GetGames == undefined){
|
if (GoGetGames == undefined){
|
||||||
var fakeGame: Game = {
|
var fakeGame: Game = {
|
||||||
gameId: "Fake Game",
|
gameId: "Fake Game",
|
||||||
title: "Fake game",
|
title: "Fake game",
|
||||||
@ -30,7 +30,7 @@ export class GamesBarComponent implements OnInit {
|
|||||||
this.activeGame = this.games[0]
|
this.activeGame = this.games[0]
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
GetGames().then((value) => {
|
GoGetGames().then((value) => {
|
||||||
console.log(value);
|
console.log(value);
|
||||||
this.games = value;
|
this.games = value;
|
||||||
if (this.games.length > 0){
|
if (this.games.length > 0){
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { Component, OnInit } from '@angular/core';
|
import { Component, OnInit } from '@angular/core';
|
||||||
import { Game } from 'src/app/interfaces/game.interface'
|
import { Game } from 'src/app/interfaces/game.interface'
|
||||||
import { GetGames } from 'src/app/services/go';
|
import { GoGetGames } from 'src/app/services/go';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-menu-games',
|
selector: 'app-menu-games',
|
||||||
@ -27,11 +27,11 @@ export class MenuGamesComponent implements OnInit {
|
|||||||
constructor() { }
|
constructor() { }
|
||||||
|
|
||||||
ngOnInit(): void {
|
ngOnInit(): void {
|
||||||
if (GetGames == undefined){
|
if (GoGetGames == undefined){
|
||||||
this.games = this.fakeGames
|
this.games = this.fakeGames
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
GetGames().then((value) => {
|
GoGetGames().then((value) => {
|
||||||
console.log(value);
|
console.log(value);
|
||||||
this.games = value;
|
this.games = value;
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user